[prev in list] [next in list] [prev in thread] [next in thread] 

List:       linux-backports
Subject:    [PATCH 10/13] backports: add irq_get_trigger_type()
From:       Hauke Mehrtens <hauke () hauke-m ! de>
Date:       2014-05-31 17:16:07
Message-ID: 1401556570-3363-11-git-send-email-hauke () hauke-m ! de
[Download RAW message or body]

This function is needed by some drivers.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/irq.h | 13 +++++++++++++
 1 file changed, 13 insertions(+)
 create mode 100644 backport/backport-include/linux/irq.h

diff --git a/backport/backport-include/linux/irq.h b/backport/backport-include/linux/irq.h
new file mode 100644
index 0000000..8b2804d
--- /dev/null
+++ b/backport/backport-include/linux/irq.h
@@ -0,0 +1,13 @@
+#ifndef __BACKPORT_LINUX_IRQ_H
+#define __BACKPORT_LINUX_IRQ_H
+#include_next <linux/irq.h>
+
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3,11,0)
+static inline u32 irq_get_trigger_type(unsigned int irq)
+{
+	struct irq_data *d = irq_get_irq_data(irq);
+	return d ? irqd_get_trigger_type(d) : 0;
+}
+#endif
+
+#endif /* __BACKPORT_LINUX_IRQ_H */
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe backports" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic