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

drm/ingenic: Convert to Linux IRQ interfaces

Drop the DRM IRQ midlayer in favor of Linux IRQ interfaces. DRM's
IRQ helpers are mostly useful for UMS drivers. Modern KMS drivers
don't benefit from using it.

This patch also fixes a bug where the driver didn't release the
IRQ.

v2:
* automatically release IRQ via devm_request_irq() (Paul)
* mention the bugfix (Sam)

Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Paul Cercueil <paul@crapouillou.net>
Link: https://patchwork.freedesktop.org/patch/msgid/20210715100258.6638-1-tzimmermann@suse.de

authored by

Thomas Zimmermann and committed by
Paul Cercueil
613ba716 0189cb57

+1 -4
+1 -4
drivers/gpu/drm/ingenic/ingenic-drm-drv.c
··· 33 33 #include <drm/drm_fourcc.h> 34 34 #include <drm/drm_gem_atomic_helper.h> 35 35 #include <drm/drm_gem_framebuffer_helper.h> 36 - #include <drm/drm_irq.h> 37 36 #include <drm/drm_managed.h> 38 37 #include <drm/drm_of.h> 39 38 #include <drm/drm_panel.h> ··· 798 799 .fops = &ingenic_drm_fops, 799 800 .gem_create_object = ingenic_drm_gem_create_object, 800 801 DRM_GEM_CMA_DRIVER_OPS, 801 - 802 - .irq_handler = ingenic_drm_irq_handler, 803 802 }; 804 803 805 804 static const struct drm_plane_funcs ingenic_drm_primary_plane_funcs = { ··· 1095 1098 encoder->possible_clones = clone_mask; 1096 1099 } 1097 1100 1098 - ret = drm_irq_install(drm, irq); 1101 + ret = devm_request_irq(dev, irq, ingenic_drm_irq_handler, 0, drm->driver->name, drm); 1099 1102 if (ret) { 1100 1103 dev_err(dev, "Unable to install IRQ handler\n"); 1101 1104 return ret;