]> www.infradead.org Git - users/jedix/linux-maple.git/commit
drm/i915: Fix PXP cleanup missing from probe error rewind
authorJanusz Krzysztofik <janusz.krzysztofik@linux.intel.com>
Fri, 14 Mar 2025 20:38:34 +0000 (21:38 +0100)
committerAndi Shyti <andi.shyti@linux.intel.com>
Wed, 19 Mar 2025 01:44:41 +0000 (02:44 +0100)
commit4cce01dc3ecdf5fb9ae75723aea7873ef52e4005
tree7fa0938ccb92c1fab437c707a95feaf8706dd6f9
parent2ae485e3d11d34cb70fcfebf149f5f4fce97f089
drm/i915: Fix PXP cleanup missing from probe error rewind

Commit f67986b0119c04 ("drm/i915/pxp: Promote pxp subsystem to top-level
of i915") added PXP initialization to driver probe path, but didn't add a
respective PXP cleanup on probe error.  That lack of cleanup seems
harmless as long as PXP is still unused and idle when a probe failure
occurs and error rewind path is entered, but as soon as PXP starts
consuming device and driver resources keeping them busy, kernel warnings
may be triggered when cleaning up resources provided by memory regions,
GGTT, GEM and/or VMA cache from the probe error rewind and/or module
unload paths because of missing PXP cleanup.  That scenario was observed
on attempts to fail the probe and enter the rewind path on injection of
now ignored error in device registration path.

Fix it.

Cc: Alan Previn <alan.previn.teres.alexis@intel.com>
Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Signed-off-by: Janusz Krzysztofik <janusz.krzysztofik@linux.intel.com>
Reviewed-by: Krzysztof Niemiec <krzysztof.niemiec@intel.com>
Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com>
Signed-off-by: Andi Shyti <andi.shyti@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250314205202.809563-7-janusz.krzysztofik@linux.intel.com
drivers/gpu/drm/i915/i915_driver.c