linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* drm: Adding the option IRQ_ONESHOT to support irq oneshot
@ 2012-08-30  8:27 Liu, Chuansheng
  0 siblings, 0 replies; only message in thread
From: Liu, Chuansheng @ 2012-08-30  8:27 UTC (permalink / raw)
  To: dri-devel, linux-kernel; +Cc: airlied, Shi, Yang A

From: liu chuansheng <chuansheng.liu@intel.com>
Subject: [PATCH] drm: Adding the option IRQ_ONESHOT to support irq oneshot

For some platforms, we want the irq is handled as one shot,
then even when we use the irq thread, with this option, the new
irq will come until the irq thread finished.

So we have the requirement for IRQ_ONESHOT.

Signed-off-by: liu chuansheng <chuansheng.liu@intel.com>
---
 drivers/gpu/drm/drm_irq.c |    3 +++
 include/drm/drmP.h        |    1 +
 2 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/drivers/gpu/drm/drm_irq.c b/drivers/gpu/drm/drm_irq.c
index 03f16f3..7a8a581 100644
--- a/drivers/gpu/drm/drm_irq.c
+++ b/drivers/gpu/drm/drm_irq.c
@@ -345,6 +345,9 @@ int drm_irq_install(struct drm_device *dev)
        if (drm_core_check_feature(dev, DRIVER_IRQ_SHARED))
                sh_flags = IRQF_SHARED;
 
+        if (drm_core_check_feature(dev, DRIVER_IRQ_ONESHOT))
+                sh_flags |= IRQF_ONESHOT;
+
        if (dev->devname)
                irqname = dev->devname;
        else
diff --git a/include/drm/drmP.h b/include/drm/drmP.h
index d6b67bb..dfede31 100644
--- a/include/drm/drmP.h
+++ b/include/drm/drmP.h
@@ -152,6 +152,7 @@ int drm_err(const char *func, const char *format, ...);
 #define DRIVER_GEM         0x1000
 #define DRIVER_MODESET     0x2000
 #define DRIVER_PRIME       0x4000
+#define DRIVER_IRQ_ONESHOT 0x8000
 
 #define DRIVER_BUS_PCI 0x1
 #define DRIVER_BUS_PLATFORM 0x2
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2012-08-30  8:27 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-08-30  8:27 drm: Adding the option IRQ_ONESHOT to support irq oneshot Liu, Chuansheng

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).