lkml.org 
[lkml]   [2015]   [Jun]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[tip:irq/urgent] genirq: Introduce helper irq_desc_get_irq()
Commit-ID:  304adf8a8fff972f633bf52b3d160682d3f3d5d2
Gitweb: http://git.kernel.org/tip/304adf8a8fff972f633bf52b3d160682d3f3d5d2
Author: Jiang Liu <jiang.liu@linux.intel.com>
AuthorDate: Thu, 4 Jun 2015 12:13:26 +0800
Committer: Thomas Gleixner <tglx@linutronix.de>
CommitDate: Fri, 26 Jun 2015 21:28:32 +0200

genirq: Introduce helper irq_desc_get_irq()

Introduce helper irq_desc_get_irq() to retrieve the irq number from
the irq descriptor.

Signed-off-by: Jiang Liu <jiang.liu@linux.intel.com>
Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: Tony Luck <tony.luck@intel.com>
Cc: Bjorn Helgaas <bhelgaas@google.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Randy Dunlap <rdunlap@infradead.org>
Cc: Yinghai Lu <yinghai@kernel.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Marc Zyngier <marc.zyngier@arm.com>
Link: http://lkml.kernel.org/r/1433391238-19471-17-git-send-email-jiang.liu@linux.intel.com
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
---
include/linux/irqdesc.h | 5 +++++
1 file changed, 5 insertions(+)

diff --git a/include/linux/irqdesc.h b/include/linux/irqdesc.h
index 66c41b4..a72bfd9 100644
--- a/include/linux/irqdesc.h
+++ b/include/linux/irqdesc.h
@@ -100,6 +100,11 @@ static inline struct irq_desc *irq_data_to_desc(struct irq_data *data)
#endif
}

+static inline unsigned int irq_desc_get_irq(struct irq_desc *desc)
+{
+ return desc->irq_data.irq;
+}
+
static inline struct irq_data *irq_desc_get_irq_data(struct irq_desc *desc)
{
return &desc->irq_data;

\
 
 \ /
  Last update: 2015-06-26 22:01    [W:0.295 / U:0.728 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site