aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStewart Smith <stewart@linux.vnet.ibm.com>2017-10-23 16:58:22 -0500
committerStewart Smith <stewart@linux.vnet.ibm.com>2017-10-29 18:48:02 -0500
commit896cb12ce237ac8e43228297f313d93c6e83e88f (patch)
tree777169f9392dca0734f4deea8bba373653cc090d
parentdd10f93c82f44d823d8664b1ffc45994003e5f1e (diff)
downloadskiboot-896cb12ce237ac8e43228297f313d93c6e83e88f.zip
skiboot-896cb12ce237ac8e43228297f313d93c6e83e88f.tar.gz
skiboot-896cb12ce237ac8e43228297f313d93c6e83e88f.tar.bz2
Suppress XSCOM chiplet-offline errors on P9
Workaround on P9: PRD does operations it *knows* will fail with this error to work around a hardware issue where accesses via the PIB (FSI or OCC) work as expected, accesses via the ADU (what xscom goes through) do not. The chip logic will always return all FFs if there is any error on the scom. Suggested-by: Daniel M Crowell <dcrowell@us.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com> Acked-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
-rw-r--r--hw/xscom.c22
1 files changed, 21 insertions, 1 deletions
diff --git a/hw/xscom.c b/hw/xscom.c
index 716cb73..5b3bd88 100644
--- a/hw/xscom.c
+++ b/hw/xscom.c
@@ -1,4 +1,4 @@
-/* Copyright 2013-2014 IBM Corp.
+/* Copyright 2013-2017 IBM Corp.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -284,6 +284,16 @@ static int __xscom_read(uint32_t gcid, uint32_t pcb_addr, uint64_t *val)
if (xscom_is_multicast_addr(pcb_addr) && ret == OPAL_XSCOM_CHIPLET_OFF)
return ret;
+ /*
+ * Workaround on P9: PRD does operations it *knows* will fail with this
+ * error to work around a hardware issue where accesses via the PIB
+ * (FSI or OCC) work as expected, accesses via the ADU (what xscom goes
+ * through) do not. The chip logic will always return all FFs if there
+ * is any error on the scom.
+ */
+ if (proc_gen == proc_gen_p9 && ret == OPAL_XSCOM_CHIPLET_OFF)
+ return ret;
+
prerror("XSCOM: Read failed, ret = %lld\n", ret);
return ret;
}
@@ -324,6 +334,16 @@ static int __xscom_write(uint32_t gcid, uint32_t pcb_addr, uint64_t val)
if (xscom_is_multicast_addr(pcb_addr) && ret == OPAL_XSCOM_CHIPLET_OFF)
return ret;
+ /*
+ * Workaround on P9: PRD does operations it *knows* will fail with this
+ * error to work around a hardware issue where accesses via the PIB
+ * (FSI or OCC) work as expected, accesses via the ADU (what xscom goes
+ * through) do not. The chip logic will always return all FFs if there
+ * is any error on the scom.
+ */
+ if (proc_gen == proc_gen_p9 && ret == OPAL_XSCOM_CHIPLET_OFF)
+ return ret;
+
prerror("XSCOM: Write failed, ret = %lld\n", ret);
return ret;
}