]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/powernv/idle: Use Requested Level for restoring state on P9 DD1
authorGautham R. Shenoy <ego@linux.vnet.ibm.com>
Tue, 16 May 2017 08:49:47 +0000 (14:19 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 30 May 2017 04:59:51 +0000 (14:59 +1000)
commitb27cb3848aaaabe12dc3fc251004866f45d28ee2
tree0e67968c50a9359fc84ee0ef1cba7b546988528c
parent5a3bd7102acc63dec351a4f5d03f7f55d0783bc2
powerpc/powernv/idle: Use Requested Level for restoring state on P9 DD1

On Power9 DD1 due to a hardware bug the Power-Saving Level Status
field (PLS) of the PSSCR for a thread waking up from a deep state can
under-report if some other thread in the core is in a shallow stop
state. The scenario in which this can manifest is as follows:

   1) All the threads of the core are in deep stop.
   2) One of the threads is woken up. The PLS for this thread will
      correctly reflect that it is waking up from deep stop.
   3) The thread that has woken up now executes a shallow stop.
   4) When some other thread in the core is woken, its PLS will reflect
      the shallow stop state.

Thus, the subsequent thread for which the PLS is under-reporting the
wakeup state will not restore the hypervisor resources.

Hence, on DD1 systems, use the Requested Level (RL) field as a
workaround to restore the contents of the hypervisor resources on the
wakeup from the stop state.

Signed-off-by: Gautham R. Shenoy <ego@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/include/asm/paca.h
arch/powerpc/kernel/asm-offsets.c
arch/powerpc/kernel/idle_book3s.S