Skip to content

Commit

Permalink
drm/i915/gt: Schedule next retirement worker first
Browse files Browse the repository at this point in the history
As we may park the gt during request retirement, we may cancel the
retirement worker only to then program the delayed worker once more.

If we schedule the next delayed retirement worker first, if we then park
the gt, the work will remain cancelled.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20191119162559.3313003-2-chris@chris-wilson.co.uk
  • Loading branch information
Chris Wilson committed Nov 19, 2019
1 parent 1683d24 commit dcbebb1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/gpu/drm/i915/gt/intel_gt_requests.c
Original file line number Diff line number Diff line change
@@ -110,9 +110,9 @@ static void retire_work_handler(struct work_struct *work)
struct intel_gt *gt =
container_of(work, typeof(*gt), requests.retire_work.work);

intel_gt_retire_requests(gt);
schedule_delayed_work(&gt->requests.retire_work,
round_jiffies_up_relative(HZ));
intel_gt_retire_requests(gt);
}

void intel_gt_init_requests(struct intel_gt *gt)

0 comments on commit dcbebb1

Please sign in to comment.