summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/idle_book3s.S
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2016-07-08 08:37:11 +0200
committerMichael Ellerman <mpe@ellerman.id.au>2016-07-17 08:42:46 +0200
commit69c592ed40d32b4b680fd46c1b059cfe8abeb755 (patch)
treefbe635a6be414b868fc22704afc9a930bb3fa79e /arch/powerpc/kernel/idle_book3s.S
parentpowerpc/pseries/pci: Remove obsolete SW invalidate (diff)
downloadlinux-69c592ed40d32b4b680fd46c1b059cfe8abeb755.tar.xz
linux-69c592ed40d32b4b680fd46c1b059cfe8abeb755.zip
powerpc/opal: Add real mode call wrappers
Replace the old generic opal_call_realmode() with proper per-call wrappers similar to the normal ones and convert callers. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/kernel/idle_book3s.S')
-rw-r--r--arch/powerpc/kernel/idle_book3s.S16
1 files changed, 5 insertions, 11 deletions
diff --git a/arch/powerpc/kernel/idle_book3s.S b/arch/powerpc/kernel/idle_book3s.S
index 1f564eb409c3..335eb6cedae5 100644
--- a/arch/powerpc/kernel/idle_book3s.S
+++ b/arch/powerpc/kernel/idle_book3s.S
@@ -245,8 +245,7 @@ fastsleep_workaround_at_entry:
/* Fast sleep workaround */
li r3,1
li r4,1
- li r0,OPAL_CONFIG_CPU_IDLE_STATE
- bl opal_call_realmode
+ bl opal_rm_config_cpu_idle_state
/* Clear Lock bit */
li r0,0
@@ -337,8 +336,7 @@ ALT_FTR_SECTION_END_NESTED_IFSET(CPU_FTR_ARCH_207S, 66); \
ld r2,PACATOC(r13); \
ld r1,PACAR1(r13); \
std r3,ORIG_GPR3(r1); /* Save original r3 */ \
- li r0,OPAL_HANDLE_HMI; /* Pass opal token argument*/ \
- bl opal_call_realmode; \
+ bl opal_rm_handle_hmi; \
ld r3,ORIG_GPR3(r1); /* Restore original r3 */ \
20: nop;
@@ -430,7 +428,7 @@ _GLOBAL(pnv_wakeup_tb_loss)
* until they are restored, they are free to be used.
*
* Save SRR1 and LR in NVGPRs as they might be clobbered in
- * opal_call_realmode (called in CHECK_HMI_INTERRUPT). SRR1 is required
+ * opal_call() (called in CHECK_HMI_INTERRUPT). SRR1 is required
* to determine the wakeup reason if we branch to kvm_start_guest. LR
* is required to return back to reset vector after hypervisor state
* restore is complete.
@@ -530,10 +528,7 @@ timebase_resync:
*/
ble cr3,clear_lock
/* Time base re-sync */
- li r0,OPAL_RESYNC_TIMEBASE
- bl opal_call_realmode;
- /* TODO: Check r3 for failure */
-
+ bl opal_rm_resync_timebase;
/*
* If waking up from sleep, per core state is not lost, skip to
* clear_lock.
@@ -622,8 +617,7 @@ hypervisor_state_restored:
fastsleep_workaround_at_exit:
li r3,1
li r4,0
- li r0,OPAL_CONFIG_CPU_IDLE_STATE
- bl opal_call_realmode
+ bl opal_rm_config_cpu_idle_state
b timebase_resync
/*