[Pdbg] [PATCH 5/8] libpdbg: Expose p9_thread_state method

Amitay Isaacs amitay at ozlabs.org
Fri Oct 9 14:59:58 AEDT 2020


This will be used by sbefifo thread to update thread status.

Signed-off-by: Amitay Isaacs <amitay at ozlabs.org>
---
 libpdbg/chip.h   | 2 ++
 libpdbg/p9chip.c | 2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/libpdbg/chip.h b/libpdbg/chip.h
index 6856c64..11e8e8b 100644
--- a/libpdbg/chip.h
+++ b/libpdbg/chip.h
@@ -43,4 +43,6 @@ int ram_putmsr(struct thread *thread, uint64_t value);
 int ram_getcr(struct thread *thread, uint32_t *value);
 int ram_putcr(struct thread *thread, uint32_t value);
 
+struct thread_state p9_thread_state(struct thread *thread);
+
 #endif
diff --git a/libpdbg/p9chip.c b/libpdbg/p9chip.c
index 05cce7f..d8187ce 100644
--- a/libpdbg/p9chip.c
+++ b/libpdbg/p9chip.c
@@ -90,7 +90,7 @@ static uint64_t thread_write(struct thread *thread, uint64_t addr, uint64_t data
 	return pib_write(chip, addr, data);
 }
 
-static struct thread_state p9_thread_state(struct thread *thread)
+struct thread_state p9_thread_state(struct thread *thread)
 {
 	uint64_t value;
 	struct thread_state thread_state;
-- 
2.26.2



More information about the Pdbg mailing list