Commit 9b6a68d9 authored by Michael Neuling's avatar Michael Neuling Committed by Benjamin Herrenschmidt

powerpc/cpuidle: Only clear LPCR decrementer wakeup bit on fast sleep entry

Currently when entering fastsleep we clear all LPCR PECE bits.

This patch changes it to only clear the decrementer bit (ie. PECE1), which is
the only bit we really need to clear here.  This is needed if we want to set
other wakeup causes like the PECEDH bit so we can use hypervisor doorbells on
powernv.  Also we no longer clear the MER bit as it should never be set in the
host anyway.
Signed-off-by: default avatarMichael Neuling <mikey@neuling.org>
Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
parent 5c7a35e3
...@@ -73,12 +73,10 @@ static int fastsleep_loop(struct cpuidle_device *dev, ...@@ -73,12 +73,10 @@ static int fastsleep_loop(struct cpuidle_device *dev,
return index; return index;
new_lpcr = old_lpcr; new_lpcr = old_lpcr;
new_lpcr &= ~(LPCR_MER | LPCR_PECE); /* lpcr[mer] must be 0 */ /* Do not exit powersave upon decrementer as we've setup the timer
* offload.
/* exit powersave upon external interrupt, but not decrementer
* interrupt.
*/ */
new_lpcr |= LPCR_PECE0; new_lpcr &= ~LPCR_PECE1;
mtspr(SPRN_LPCR, new_lpcr); mtspr(SPRN_LPCR, new_lpcr);
power7_sleep(); power7_sleep();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment