aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/cpu.c7
-rw-r--r--hw/slw.c3
2 files changed, 10 insertions, 0 deletions
diff --git a/core/cpu.c b/core/cpu.c
index 1b523f6..cd29957 100644
--- a/core/cpu.c
+++ b/core/cpu.c
@@ -679,6 +679,13 @@ static int64_t opal_reinit_cpus(uint64_t flags)
rc = cpu_change_all_hile(hile);
}
+ /* If we have a P7, error out for LE switch, do nothing for BE */
+ if (proc_gen < proc_gen_p8) {
+ if (flags & OPAL_REINIT_CPUS_HILE_LE)
+ rc = OPAL_UNSUPPORTED;
+ flags &= ~(OPAL_REINIT_CPUS_HILE_BE | OPAL_REINIT_CPUS_HILE_LE);
+ }
+
/* Any flags left ? */
if (flags != 0)
rc = slw_reinit(flags);
diff --git a/hw/slw.c b/hw/slw.c
index 3f3f649..30f9420 100644
--- a/hw/slw.c
+++ b/hw/slw.c
@@ -751,6 +751,9 @@ int64_t slw_reinit(uint64_t flags)
return OPAL_UNSUPPORTED;
#endif
+ if (proc_gen < proc_gen_p8)
+ return OPAL_UNSUPPORTED;
+
if (flags & OPAL_REINIT_CPUS_HILE_BE)
target_le = false;
if (flags & OPAL_REINIT_CPUS_HILE_LE)