aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/omapdrm/omap_drv.h
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@ti.com>2013-10-24 02:50:50 -0400
committerTomi Valkeinen <tomi.valkeinen@ti.com>2014-01-09 08:15:24 -0500
commit6da9f89172b94411896130c6e1acf159da3dc760 (patch)
treefb656b3cd9cdb5973f6891ccde3be5fb4fcb739a /drivers/gpu/drm/omapdrm/omap_drv.h
parent802eee95bde72fd0cd0f3a5b2098375a487d1eda (diff)
drm/omap: fix (un)registering irqs inside an irq handler
omapdrm (un)registers irqs inside an irq handler. The problem is that the (un)register function uses dispc_runtime_get/put() to enable the clocks, and those functions are not irq safe by default. This was kind of fixed in 48664b21aeeffb40c5fa06843f18052e2c4ec9ef (OMAPDSS: DISPC: set irq_safe for runtime PM), which makes dispc's runtime calls irq-safe. However, using pm_runtime_irq_safe in dispc makes the parent of dispc, dss, always enabled, effectively preventing PM for the whole DSS module. This patch makes omapdrm behave better by adding new irq (un)register functions that do not use dispc_runtime_get/put, and using those functions in interrupt context. Thus we can make dispc again non-irq-safe, allowing proper PM. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: Rob Clark <robdclark@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/omapdrm/omap_drv.h')
-rw-r--r--drivers/gpu/drm/omapdrm/omap_drv.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/omapdrm/omap_drv.h b/drivers/gpu/drm/omapdrm/omap_drv.h
index 07847693cf49..e835c27c5ad4 100644
--- a/drivers/gpu/drm/omapdrm/omap_drv.h
+++ b/drivers/gpu/drm/omapdrm/omap_drv.h
@@ -145,6 +145,8 @@ irqreturn_t omap_irq_handler(DRM_IRQ_ARGS);
145void omap_irq_preinstall(struct drm_device *dev); 145void omap_irq_preinstall(struct drm_device *dev);
146int omap_irq_postinstall(struct drm_device *dev); 146int omap_irq_postinstall(struct drm_device *dev);
147void omap_irq_uninstall(struct drm_device *dev); 147void omap_irq_uninstall(struct drm_device *dev);
148void __omap_irq_register(struct drm_device *dev, struct omap_drm_irq *irq);
149void __omap_irq_unregister(struct drm_device *dev, struct omap_drm_irq *irq);
148void omap_irq_register(struct drm_device *dev, struct omap_drm_irq *irq); 150void omap_irq_register(struct drm_device *dev, struct omap_drm_irq *irq);
149void omap_irq_unregister(struct drm_device *dev, struct omap_drm_irq *irq); 151void omap_irq_unregister(struct drm_device *dev, struct omap_drm_irq *irq);
150int omap_drm_irq_uninstall(struct drm_device *dev); 152int omap_drm_irq_uninstall(struct drm_device *dev);