diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/channel_gk20a.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/channel_gk20a.c b/drivers/gpu/nvgpu/gk20a/channel_gk20a.c index 344223ae..00f8ac94 100644 --- a/drivers/gpu/nvgpu/gk20a/channel_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/channel_gk20a.c | |||
@@ -1423,11 +1423,12 @@ void gk20a_channel_update(struct channel_gk20a *c, int nr_completed) | |||
1423 | /* | 1423 | /* |
1424 | * If job list is empty then channel is idle and we can free | 1424 | * If job list is empty then channel is idle and we can free |
1425 | * the syncpt here (given aggressive_destroy flag is set) | 1425 | * the syncpt here (given aggressive_destroy flag is set) |
1426 | * Note: if WFI is already scheduled on some other path | 1426 | * Note: check if last submit is complete before destroying |
1427 | * then syncpt is still required to check for idle | 1427 | * the sync resource |
1428 | */ | 1428 | */ |
1429 | if (list_empty(&c->jobs) && !c->last_submit_fence.wfi) { | 1429 | if (list_empty(&c->jobs)) { |
1430 | if (c->sync && c->sync->syncpt_aggressive_destroy) { | 1430 | if (c->sync && c->sync->syncpt_aggressive_destroy && |
1431 | c->sync->is_expired(c->sync, &c->last_submit_fence)) { | ||
1431 | c->sync->destroy(c->sync); | 1432 | c->sync->destroy(c->sync); |
1432 | c->sync = NULL; | 1433 | c->sync = NULL; |
1433 | } | 1434 | } |