]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
drm/xe/pmu: Fail probe if xe_pmu_register() fails
authorLucas De Marchi <lucas.demarchi@intel.com>
Thu, 13 Feb 2025 19:29:08 +0000 (11:29 -0800)
committerLucas De Marchi <lucas.demarchi@intel.com>
Fri, 14 Feb 2025 19:42:55 +0000 (11:42 -0800)
Now that previous callers in xe_device_probe() are handling the errors,
that can be done for xe_pmu_register() as well.

Cc: Riana Tauro <riana.tauro@intel.com>
Cc: Vinay Belgaumkar <vinay.belgaumkar@intel.com>
Reviewed-by: Tejas Upadhyay <tejas.upadhyay@intel.com>
Reviewed-by: Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250213192909.996148-12-lucas.demarchi@intel.com
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
drivers/gpu/drm/xe/xe_device.c

index 89a85f193f3af5692c7038e2c2540d324d41c207..6718b7c2d1ea1464b677bce7d7f0f26043d12cc4 100644 (file)
@@ -889,7 +889,9 @@ int xe_device_probe(struct xe_device *xe)
        if (err)
                goto err_unregister_display;
 
-       xe_pmu_register(&xe->pmu);
+       err = xe_pmu_register(&xe->pmu);
+       if (err)
+               goto err_unregister_display;
 
        xe_debugfs_register(xe);