Skip to content

Commit aee5ae7

Browse files
unerligerodrigovivi
authored andcommitted
drm/i915/guc: Cancel GuC engine busyness worker synchronously
The worker is canceled in gt_park path, but earlier it was assumed that gt_park path cannot sleep and the cancel is asynchronous. This caused a race with suspend flow where the worker runs after suspend and causes an unclaimed register access warning. Cancel the worker synchronously since the gt_park is indeed allowed to sleep. v2: Fix author name and sign-off mismatch Signed-off-by: Umesh Nerlige Ramappa <[email protected]> Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/4419 Fixes: 77cdd05 ("drm/i915/pmu: Connect engine busyness stats from GuC to pmu") Reviewed-by: Ashutosh Dixit <[email protected]> Signed-off-by: John Harrison <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Signed-off-by: Joonas Lahtinen <[email protected]> (cherry picked from commit 31335aa) Signed-off-by: Rodrigo Vivi <[email protected]>
1 parent 08b8129 commit aee5ae7

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

drivers/gpu/drm/i915/gt/uc/intel_guc_submission.c

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1438,7 +1438,12 @@ void intel_guc_busyness_park(struct intel_gt *gt)
14381438
if (!guc_submission_initialized(guc))
14391439
return;
14401440

1441-
cancel_delayed_work(&guc->timestamp.work);
1441+
/*
1442+
* There is a race with suspend flow where the worker runs after suspend
1443+
* and causes an unclaimed register access warning. Cancel the worker
1444+
* synchronously here.
1445+
*/
1446+
cancel_delayed_work_sync(&guc->timestamp.work);
14421447

14431448
/*
14441449
* Before parking, we should sample engine busyness stats if we need to.

0 commit comments

Comments
 (0)