msm: kgsl: Update internal timestamp when preemption is toggled
Say preemption is enabled and a context is bound to ringbuffer-1.
It's internal timestamp say is 0x4000. Now if we disable preemption,
all the contexts are bound to ringbuffer-0. Now, say the context
is going away. The context destroy path will check timestamp 0x4000
which is from the stale ringbuffer, against ringbuffer-0, and its very
likely that ringbuffer-0's timestamp is less than 0x4000 which will
cause a false context-detach fault. Fix this by updating the context's
internal timestamp to the last retired timestamp on the new ringbuffer.
Also, toggle preemption only if ringbuffers are completely drained.
Change-Id: I674978593b11df3998765017c270c3f0dde6c0a5
Signed-off-by:
Harshdeep Dhatt <hdhatt@codeaurora.org>
Loading
Please register or sign in to comment