[Skiboot] [PATCH v3 2/2] xive: Fix opal_xive_dump_tm() to access W2 properly
Benjamin Herrenschmidt
benh at kernel.crashing.org
Wed Sep 13 13:37:26 AEST 2017
The HW only supported limited access sizes.
Signed-off-by: Benjamin Herrenschmidt <benh at kernel.crashing.org>
---
hw/xive.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/hw/xive.c b/hw/xive.c
index 21dd3d95..26edd669 100644
--- a/hw/xive.c
+++ b/hw/xive.c
@@ -4733,7 +4733,13 @@ static int64_t opal_xive_dump_tm(uint32_t offset, const char *n, uint32_t pir)
xive_regr(x, PC_TCTXT_INDIR0);
v0 = in_be64(ind_tm_base + offset);
- v1 = in_be64(ind_tm_base + offset + 8);
+ if (offset == TM_QW3_HV_PHYS) {
+ v1 = in_8(ind_tm_base + offset + 8);
+ v1 <<= 56;
+ } else {
+ v1 = in_be32(ind_tm_base + offset + 8);
+ v1 <<= 32;
+ }
prlog(PR_INFO, "CPU[%04x]: TM state for QW %s\n", pir, n);
prlog(PR_INFO, "CPU[%04x]: NSR CPPR IPB LSMFB ACK# INC AGE PIPR"
" W2 W3\n", pir);
--
2.13.5
More information about the Skiboot
mailing list