[Pdbg] [PATCH v2 08/12] libpdbg: Add api for thread control via sbe
Amitay Isaacs
amitay at ozlabs.org
Thu Jul 4 18:05:21 AEST 2019
Signed-off-by: Amitay Isaacs <amitay at ozlabs.org>
---
libpdbg/libpdbg.h | 1 +
libpdbg/target.c | 10 ++++++++++
2 files changed, 11 insertions(+)
diff --git a/libpdbg/libpdbg.h b/libpdbg/libpdbg.h
index b9b271f..e193260 100644
--- a/libpdbg/libpdbg.h
+++ b/libpdbg/libpdbg.h
@@ -239,6 +239,7 @@ int opb_read(struct pdbg_target *target, uint32_t addr, uint32_t *data);
int opb_write(struct pdbg_target *target, uint32_t addr, uint32_t data);
int sbe_istep(struct pdbg_target *target, uint32_t major, uint32_t minor);
+int sbe_control(struct pdbg_target *target, uint32_t core_id, uint32_t thread_id, uint32_t oper);
uint32_t sbe_ffdc_get(struct pdbg_target *target, const uint8_t **ffdc, uint32_t *ffdc_len);
void sbe_ffdc_dump(struct pdbg_target *target);
diff --git a/libpdbg/target.c b/libpdbg/target.c
index 9495d61..f7f16bf 100644
--- a/libpdbg/target.c
+++ b/libpdbg/target.c
@@ -275,6 +275,16 @@ int sbe_istep(struct pdbg_target *target, uint32_t major, uint32_t minor)
return sbefifo->istep(sbefifo, major, minor);
}
+int sbe_control(struct pdbg_target *target, uint32_t core_id, uint32_t thread_id, uint32_t oper)
+{
+ struct sbefifo *sbefifo;
+
+ assert(pdbg_target_is_class(target, "sbefifo"));
+
+ sbefifo = target_to_sbefifo(target);
+ return sbefifo->control(sbefifo, core_id, thread_id, oper);
+}
+
uint32_t sbe_ffdc_get(struct pdbg_target *target, const uint8_t **ffdc, uint32_t *ffdc_len)
{
struct sbefifo *sbefifo;
--
2.21.0
More information about the Pdbg
mailing list