summaryrefslogtreecommitdiffstats
path: root/hdata
diff options
context:
space:
mode:
authorNicholas Piggin <npiggin@gmail.com>2017-09-20 16:56:03 +1000
committerStewart Smith <stewart@linux.vnet.ibm.com>2017-09-20 23:25:01 -0500
commit5e09fe1f19d3f56b1cebb44439da5b5de6e1fccd (patch)
tree159d5c1c26a8068df3ec6cc623f5db7e3bfa8310 /hdata
parent5779c11fdc57c4dc474beb00f044f34ec1c58368 (diff)
downloadblackbird-skiboot-5e09fe1f19d3f56b1cebb44439da5b5de6e1fccd.tar.gz
blackbird-skiboot-5e09fe1f19d3f56b1cebb44439da5b5de6e1fccd.zip
core: POWER9 implement OPAL_SIGNAL_SYSTEM_RESET
This implements OPAL_SIGNAL_SYSTEM_RESET, using scom registers to quiesce the target thread and raise a system reset exception on it. It has been tested on DD2 with stop0 ESL=0 and ESL=1 shallow power saving modes. DD1 is not implemented because it is sufficiently different as to make support difficult. Signed-off-by: Nicholas Piggin <npiggin@gmail.com> [stewart@linux.vnet.ibm.com: fixup hdat_to_dt test] Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hdata')
-rw-r--r--hdata/hdata.h14
-rw-r--r--hdata/test/hdata_to_dt.c15
2 files changed, 15 insertions, 14 deletions
diff --git a/hdata/hdata.h b/hdata/hdata.h
index 82479f52..2e4840f4 100644
--- a/hdata/hdata.h
+++ b/hdata/hdata.h
@@ -36,20 +36,6 @@ extern void vpd_data_parse(struct dt_node *node,
extern struct dt_node *find_xscom_for_chip(uint32_t chip_id);
extern uint32_t pcid_to_chip_id(uint32_t proc_chip_id);
-static __unused bool is_power9n(uint32_t version)
-{
- if (PVR_TYPE(version) != PVR_TYPE_P9)
- return false;
- /*
- * Bit 13 tells us:
- * 0 = Scale out (aka Nimbus)
- * 1 = Scale up (aka Cumulus)
- */
- if ((version >> 13) & 1)
- return false;
- return true;
-}
-
extern struct dt_node *add_core_common(struct dt_node *cpus,
const struct sppaca_cpu_cache *cache,
const struct sppaca_cpu_timebase *tb,
diff --git a/hdata/test/hdata_to_dt.c b/hdata/test/hdata_to_dt.c
index 155e41b6..f5979148 100644
--- a/hdata/test/hdata_to_dt.c
+++ b/hdata/test/hdata_to_dt.c
@@ -98,6 +98,21 @@ struct dt_node *add_ics_node(void)
return NULL;
}
+// Copied from processor.h:
+static inline bool is_power9n(uint32_t version)
+{
+ if (PVR_TYPE(version) != PVR_TYPE_P9)
+ return false;
+ /*
+ * Bit 13 tells us:
+ * 0 = Scale out (aka Nimbus)
+ * 1 = Scale up (aka Cumulus)
+ */
+ if ((version >> 13) & 1)
+ return false;
+ return true;
+}
+
#include <config.h>
#include <bitutils.h>
OpenPOWER on IntegriCloud