]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
drm: zynqmp_kms: Unplug DRM device before removal
authorSean Anderson <sean.anderson@linux.dev>
Fri, 9 Aug 2024 19:35:53 +0000 (15:35 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 5 Dec 2024 12:53:18 +0000 (13:53 +0100)
commit4fb97432e28a7e136b2d76135d50e988ada8e1af
tree5e3ee99deec1b4506184309b381999b9a951d443
parent22b4a623c0f230540f02f4358744cce62ae12dbf
drm: zynqmp_kms: Unplug DRM device before removal

[ Upstream commit 2e07c88914fc5289c21820b1aa94f058feb38197 ]

Prevent userspace accesses to the DRM device from causing
use-after-frees by unplugging the device before we remove it. This
causes any further userspace accesses to result in an error without
further calls into this driver's internals.

Fixes: d76271d22694 ("drm: xlnx: DRM/KMS driver for Xilinx ZynqMP DisplayPort Subsystem")
Closes: https://lore.kernel.org/dri-devel/4d8f4c9b-2efb-4774-9a37-2f257f79b2c9@linux.dev/
Signed-off-by: Sean Anderson <sean.anderson@linux.dev>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240809193600.3360015-2-sean.anderson@linux.dev
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/xlnx/zynqmp_kms.c