[Pdbg] [PATCH 06/14] libpdbg/p9chip.c: use the OTR special wakeup status latch
Nicholas Piggin
npiggin at gmail.com
Mon Apr 9 17:35:14 AEST 2018
Use this to poll for special wakeup done (like skiboot does with
the HYP latch).
Signed-off-by: Nicholas Piggin <npiggin at gmail.com>
---
libpdbg/p9chip.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/libpdbg/p9chip.c b/libpdbg/p9chip.c
index a969ef6..2a5020b 100644
--- a/libpdbg/p9chip.c
+++ b/libpdbg/p9chip.c
@@ -40,6 +40,7 @@
#define NET_CTRL0_CHIPLET_ENABLE PPC_BIT(0)
#define PPM_GPMMR 0xf0100
#define PPM_SPWKUP_OTR 0xf010a
+#define PPM_SSHOTR 0xf0113
#define SPECIAL_WKUP_DONE PPC_BIT(1)
#define RAS_STATUS_TIMEOUT 100 /* 100ms */
@@ -225,7 +226,7 @@ static int p9_core_probe(struct pdbg_target *target)
CHECK_ERR(pib_write(target, PPM_SPWKUP_OTR, PPC_BIT(0)));
do {
usleep(1000);
- CHECK_ERR(pib_read(target, PPM_GPMMR, &value));
+ CHECK_ERR(pib_read(target, PPM_SSHOTR, &value));
if (i++ > SPECIAL_WKUP_TIMEOUT) {
PR_ERROR("Timeout waiting for special wakeup on %s at 0x%08" PRIx64 "\n", target->name,
--
2.17.0
More information about the Pdbg
mailing list