gpu: pvr: make sure the device is powered on in SGX_MISRHandler
While SGX_MISRHandler is scheduled another code path of the driver
(IOCTL, SGXOSTimer) can race with it and turn the power off before
it starts to execute.
When this happens we get the following oops backtrace:
HWRecoveryResetSGX: SGX Hardware Recovery triggered
Unhandled fault: external abort on non-linefetch (0x1008)
PC is at HWRecoveryResetSGX+0x74/0x1b8 [pvrsrvkm]
LR is at preempt_schedule+0x44/0x54
(HWRecoveryResetSGX+0x0/0x1b8) from (SGX_MISRHandler+0x5c/0x60)
(SGX_MISRHandler+0x0/0x60) from (PVRSRVMISR+0x44/0xa0)
r5:
bf0a29cc r4:
dfbbbcc0
(PVRSRVMISR+0x0/0xa0) from (MISRWrapper+0x14/0x18)
r5:
00000002 r4:
00000000
(MISRWrapper+0x0/0x18) from (worker_thread+0x1d0/0x2cc)
(worker_thread+0x0/0x2cc) from (kthread+0x88/0x90)
(kthread+0x0/0x90) from (do_exit+0x0/0x680)
Signed-off-by: Imre Deak <imre.deak@nokia.com>