]> www.infradead.org Git - users/hch/misc.git/commitdiff
drm/xe/guc: Don't invoke disable_ct action during replacement
authorMichal Wajdeczko <michal.wajdeczko@intel.com>
Mon, 8 Sep 2025 10:20:52 +0000 (12:20 +0200)
committerMichal Wajdeczko <michal.wajdeczko@intel.com>
Tue, 9 Sep 2025 18:38:26 +0000 (20:38 +0200)
During second CT initialization step, known as post_hwconfig, we
want to replace previously registered CT disable devm action to
make sure it will be invoked prior to releasing underlying BO.

But to replace this action we don't need to execute it right away
since we know that CT was disabled prior to that late init step
and we already assert that. Use devm_remove_action() instead to
avoid extra message about 'disabling CT' that could be seen now:

 [drm:guc_ct_change_state [xe]] GT0: GuC CT communication channel disabled
 ...
 DEVRES REM ff11000149320940 guc_action_disable_ct (16 bytes)
 [drm:guc_ct_change_state [xe]] GT0: GuC CT communication channel disabled
 DEVRES ADD ff110001664fc040 guc_action_disable_ct (16 bytes)

Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Cc: Satyanarayana K V P <satyanarayana.k.v.p@intel.com>
Cc: Matthew Brost <matthew.brost@intel.com>
Reviewed-by: Satyanarayana K V P <satyanarayana.k.v.p@intel.com>
Link: https://lore.kernel.org/r/20250908102053.539-3-michal.wajdeczko@intel.com
drivers/gpu/drm/xe/xe_guc_ct.c

index 12372d5b7067602175e3baf181ff930106f71fed..bb8650fdeb45726d169568467b9dede2f4d75860 100644 (file)
@@ -306,7 +306,7 @@ int xe_guc_ct_init_post_hwconfig(struct xe_guc_ct *ct)
                        return ret;
        }
 
-       devm_release_action(xe->drm.dev, guc_action_disable_ct, ct);
+       devm_remove_action(xe->drm.dev, guc_action_disable_ct, ct);
        return devm_add_action_or_reset(xe->drm.dev, guc_action_disable_ct, ct);
 }