diff --git a/drivers/gpu/drm/xe/xe_device.c b/drivers/gpu/drm/xe/xe_device.c index 7007b6113760..d25d02b24898 100644 --- a/drivers/gpu/drm/xe/xe_device.c +++ b/drivers/gpu/drm/xe/xe_device.c @@ -1141,6 +1141,12 @@ int xe_device_probe(struct xe_device *xe) if (err) goto err_unregister_display; + /* + * Process and log any errors detected by hardware. Possible results can + * include declaring the device as wedged, which must be done only after + * xe_device_wedged_fini() is registered. + */ + xe_ras_process_errors(xe); return devm_add_action_or_reset(xe->drm.dev, xe_device_sanitize, xe); err_unregister_display: diff --git a/drivers/gpu/drm/xe/xe_ras.c b/drivers/gpu/drm/xe/xe_ras.c index a31e06b8aa67..c8d40289b4fe 100644 --- a/drivers/gpu/drm/xe/xe_ras.c +++ b/drivers/gpu/drm/xe/xe_ras.c @@ -692,12 +692,6 @@ void xe_ras_init(struct xe_device *xe) if (IS_ENABLED(CONFIG_PCIEAER)) ras_usp_aer_init(xe); - /* - * During probe, process and log any errors detected by firmware while the driver was not - * loaded. Critical errors such as Punit and CSC are reported through Pcode init failure, - * causing the driver to enter survivability mode. - */ - xe_ras_process_errors(xe); ret = devm_device_add_group(xe->drm.dev, &gpu_health_group); if (ret) xe_err(xe, "Failed to create GPU health sysfs, err=%d\n", ret);