msm: kgsl: After timeout check if timestamp has retired

When a thread times out while waiting for a timestamp, check once
whether the timestamp which it was waiting for has expired or not
before treating it as an error

Change-Id: Iffba7955de58974a8d990a589b926e10f6c6a481
Signed-off-by: Shubhraprakash Das <sadas@codeaurora.org>
This commit is contained in:
Shubhraprakash Das 2012-03-10 13:24:54 -07:00 committed by Stephen Boyd
parent 5fed32c16c
commit d76281c676

View file

@ -1746,6 +1746,13 @@ static int adreno_waittimestamp(struct kgsl_device *device,
} while (time_elapsed < msecs);
hang_dump:
/*
* Check if timestamp has retired here because we may have hit
* recovery which can take some time and cause waiting threads
* to timeout
*/
if (kgsl_check_timestamp(device, context, timestamp))
goto done;
status = -ETIMEDOUT;
KGSL_DRV_ERR(device,
"Device hang detected while waiting for timestamp: "