lkml.org 
[lkml]   [2010]   [Oct]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] genirq: Add single IRQ reservation helper.
For cases that wish to reserve a single IRQ simply provide a wrapper in
to the ranged reservation routine.

Signed-off-by: Paul Mundt <lethal@linux-sh.org>

---

I picked irq_reserve_irq() to follow the irq_alloc_descs/desc naming
scheme, but perhaps irq_reserve() or irq_reserve_at() is less visually
offensive? Feel free to mangle away as necessary :-)

include/linux/irq.h | 5 +++++
1 file changed, 5 insertions(+)

diff --git a/include/linux/irq.h b/include/linux/irq.h
index e963911..abde252 100644
--- a/include/linux/irq.h
+++ b/include/linux/irq.h
@@ -412,6 +412,11 @@ static inline void irq_free_desc(unsigned int irq)
irq_free_descs(irq, 1);
}

+static inline int irq_reserve_irq(unsigned int irq)
+{
+ return irq_reserve_irqs(irq, 1);
+}
+
#endif /* CONFIG_GENERIC_HARDIRQS */

#endif /* !CONFIG_S390 */

\
 
 \ /
  Last update: 2010-10-26 09:23    [W:0.025 / U:0.816 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site