Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/qxl: Fix missing KMS poll cleanup

drm_kms_helper_poll_init() initializes the output polling work and
enables polling for the DRM device. qxl enables polling before calling
drm_dev_register(), but the drm_dev_register() failure path tears down
the modeset and device state without disabling the polling helper.

The remove path also unregisters and shuts down the DRM device without
first disabling the polling helper. Add matching drm_kms_helper_poll_fini()
calls in both paths so the delayed polling work is cancelled before qxl
tears down the associated modeset/device state.

Signed-off-by: Myeonghun Pak <mhun512@gmail.com>
Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de>
Fixes: 5ff91e442652 ("qxl: use drm helper hotplug support")
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Link: https://patch.msgid.link/20260424112543.57819-1-mhun512@gmail.com

authored by

Myeonghun Pak and committed by
Thomas Zimmermann
8acd2d7e 84d5d76c

+4 -2
+4 -2
drivers/gpu/drm/qxl/qxl_drv.c
··· 118 118 /* Complete initialization. */ 119 119 ret = drm_dev_register(&qdev->ddev, ent->driver_data); 120 120 if (ret) 121 - goto modeset_cleanup; 121 + goto poll_fini; 122 122 123 123 drm_client_setup(&qdev->ddev, NULL); 124 124 return 0; 125 125 126 - modeset_cleanup: 126 + poll_fini: 127 + drm_kms_helper_poll_fini(&qdev->ddev); 127 128 qxl_modeset_fini(qdev); 128 129 unload: 129 130 qxl_device_fini(qdev); ··· 155 154 { 156 155 struct drm_device *dev = pci_get_drvdata(pdev); 157 156 157 + drm_kms_helper_poll_fini(dev); 158 158 drm_dev_unregister(dev); 159 159 drm_atomic_helper_shutdown(dev); 160 160 if (pci_is_vga(pdev) && pdev->revision < 5)