Skip to content

Commit b11a020

Browse files
hoganderlucasdemarchi
authored andcommitted
drm/xe: Do clean shutdown also when using flr
Currently Xe driver is triggering flr without any clean-up on shutdown. This is causing random warnings from pending related works as the underlying hardware is reset in the middle of their execution. Fix this by performing clean shutdown also when using flr. Fixes: 501d799 ("drm/xe: Wire up device shutdown handler") Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Jouni Högander <jouni.hogander@intel.com> Reviewed-by: Maarten Lankhorst <dev@lankhorst.se> Link: https://patch.msgid.link/20251031122312.1836534-1-jouni.hogander@intel.com Signed-off-by: Maarten Lankhorst <dev@lankhorst.se> (cherry picked from commit a4ff26b) Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
1 parent 9cd27ee commit b11a020

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

drivers/gpu/drm/xe/xe_device.c

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -983,21 +983,21 @@ void xe_device_remove(struct xe_device *xe)
983983

984984
void xe_device_shutdown(struct xe_device *xe)
985985
{
986+
struct xe_gt *gt;
987+
u8 id;
988+
986989
drm_dbg(&xe->drm, "Shutting down device\n");
987990

988-
if (xe_driver_flr_disabled(xe)) {
989-
struct xe_gt *gt;
990-
u8 id;
991+
xe_display_pm_shutdown(xe);
991992

992-
xe_display_pm_shutdown(xe);
993+
xe_irq_suspend(xe);
993994

994-
xe_irq_suspend(xe);
995+
for_each_gt(gt, xe, id)
996+
xe_gt_shutdown(gt);
995997

996-
for_each_gt(gt, xe, id)
997-
xe_gt_shutdown(gt);
998+
xe_display_pm_shutdown_late(xe);
998999

999-
xe_display_pm_shutdown_late(xe);
1000-
} else {
1000+
if (!xe_driver_flr_disabled(xe)) {
10011001
/* BOOM! */
10021002
__xe_driver_flr(xe);
10031003
}

0 commit comments

Comments
 (0)