drm/xe/pxp: Fail the load if PXP fails to initialize
authorDaniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Mon, 3 Feb 2025 23:48:57 +0000 (15:48 -0800)
committerDaniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Tue, 4 Feb 2025 22:49:18 +0000 (14:49 -0800)
commit9c9dc9ba4a00510c624588d9860968b26803a2b8
treee8bece9fcd8c4262910abe9290e24a3118293303
parent459777724d306315070d24608fcd89aea85516d6
drm/xe/pxp: Fail the load if PXP fails to initialize

The PXP implementation mimics the i915 approach of allowing the load
to continue even if PXP init has failed. On Xe however we're taking an
harder stance on boot error and only allowing the load to complete if
everything is working, so update the code to fail if anything goes wrong
during PXP init.

While at it, update the return code in case of PXP not supported to be 0
instead of EOPNOTSUPP, to follow the standard of functions called by
xe_device_probe where every non-zero value means failure.

Suggested-by: Lucas De Marchi <lucas.demarchi@intel.com>
Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Cc: Lucas De Marchi <lucas.demarchi@intel.com>
Cc: John Harrison <John.C.Harrison@Intel.com>
Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250203234857.1419637-1-daniele.ceraolospurio@intel.com
drivers/gpu/drm/xe/xe_device.c
drivers/gpu/drm/xe/xe_pxp.c