]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/powernv: Get STF barrier requirements from device-tree
authorRussell Currey <ruscur@russell.cc>
Mon, 4 Apr 2022 10:15:36 +0000 (20:15 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Sun, 22 May 2022 05:58:28 +0000 (15:58 +1000)
commit5f53f0725f6a28156e8571df6c05676ae4562c08
tree4a3cc722ffafadf9879e3b3f67de6b846a8029d1
parentd689c5d814c344a5d052c7f0a7b462020fa7f199
powerpc/powernv: Get STF barrier requirements from device-tree

The device-tree property no-need-store-drain-on-priv-state-switch is
equivalent to H_CPU_BEHAV_NO_STF_BARRIER from the
H_CPU_GET_CHARACTERISTICS hcall on pseries.

Since commit 88632ca22cfe ("powerpc/security: Add a security feature for
STF barrier") powernv systems with this device-tree property have been
enabling the STF barrier when they have no need for it.  This patch
fixes this by clearing the STF barrier feature on those systems.

Fixes: 88632ca22cfe ("powerpc/security: Add a security feature for STF barrier")
Reported-by: Joel Stanley <joel@jms.id.au>
Signed-off-by: Russell Currey <ruscur@russell.cc>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20220404101536.104794-2-ruscur@russell.cc
arch/powerpc/platforms/powernv/setup.c