gic: make sure ProcessorSleep bit clear successfully
GICR_WAKER.ProcessorSleep can only be set to zero when:
— GICR_WAKER.Sleep bit == 0.
— GICR_WAKER.Quiescent bit == 0.
On some platforms, when system reboot with GIC in sleep
mode but with power ON, such as on NXP's i.MX8QM, Linux
kernel enters suspend but could be requested to reboot,
and GIC is in sleep mode and it is inside a power domain
which is ON in this scenario, when CPU reset, the GIC
driver trys to set CORE's redistributor interface to awake,
with GICR_WAKER.Sleep bit and GICR_WAKER.Quiescent bit
both set, the ProcessorSleep bit will never be clear
and cause system hang.
This patch makes sure GICR_WAKER.Sleep bit and
GICR_WAKER.Quiescent bit are both zeor before clearing
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit 4436f3a49a47a778d7a30afb6ef2b0ef3f1f21c5)
1 file changed