Skip to content

Commit

Permalink
MALI: midgard: ARM: patch for fence timeout in monkey test
Browse files Browse the repository at this point in the history
comes from mali support case [TAC674871].

Change-Id: I5e7c54190e24eea0306a9d64545482c6209a2c0d
Signed-off-by: chenzhen <chenzhen@rock-chips.com>
  • Loading branch information
chenzhen authored and rkhuangtao committed Nov 7, 2016
1 parent a1d4faf commit 1729873
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions drivers/gpu/arm/midgard/mali_kbase_js.c
Original file line number Diff line number Diff line change
Expand Up @@ -1595,6 +1595,9 @@ static kbasep_js_release_result kbasep_js_runpool_release_ctx_internal(
if (new_ref_count == 0 &&
(!kbasep_js_is_submit_allowed(js_devdata, kctx) ||
kbdev->pm.suspending)) {
int num_slots = kbdev->gpu_props.num_job_slots;
int slot;

/* Last reference, and we've been told to remove this context
* from the Run Pool */
dev_dbg(kbdev->dev, "JS: RunPool Remove Context %p because as_busy_refcount=%d, jobs=%d, allowed=%d",
Expand Down Expand Up @@ -1637,6 +1640,14 @@ static kbasep_js_release_result kbasep_js_runpool_release_ctx_internal(
* other thread will be operating in this
* code whilst we are
*/

/* Recalculate pullable status for all slots */
for (slot = 0; slot < num_slots; slot++) {
if (kbase_js_ctx_pullable(kctx, slot, false))
kbase_js_ctx_list_add_pullable_nolock(kbdev,
kctx, slot);
}

spin_unlock_irqrestore(&js_devdata->runpool_irq.lock, flags);

kbase_backend_release_ctx_noirq(kbdev, kctx);
Expand Down

0 comments on commit 1729873

Please sign in to comment.