msm: kgsl: Set fault bit and trigger recovery if WPTR update fails

WPTR update can fail if fence status doesn't change to allow mode
from drop mode either because GMU is in bad state or its taking
more than specified timeout value to change the fence status to
allow mode.

If WPTR update fails, set the fault bit and schedule dispatcher
to make sure recovery is triggered.

Change-Id: I139a16da5e7a19b3056318f7392d2710112a88e1
Signed-off-by: Deepak Kumar <dkumar@codeaurora.org>
tirimbino
Deepak Kumar 6 years ago committed by Gerrit - the friendly Code Review server
parent 786e83fbee
commit 482de9424e
  1. 7
      drivers/gpu/msm/adreno_ringbuffer.c

@ -116,8 +116,11 @@ static void adreno_ringbuffer_wptr(struct adreno_device *adreno_dev,
rb->wptr = rb->_wptr;
spin_unlock_irqrestore(&rb->preempt_lock, flags);
if (ret)
kgsl_device_snapshot(KGSL_DEVICE(adreno_dev), NULL, false);
if (ret) {
/* If WPTR update fails, set the fault and trigger recovery */
adreno_set_gpu_fault(adreno_dev, ADRENO_GMU_FAULT);
adreno_dispatcher_schedule(KGSL_DEVICE(adreno_dev));
}
}

Loading…
Cancel
Save