Commit-ID:  c64301a230a64dfc2fcf4581cd98a2d703f3c057
Gitweb:     http://git.kernel.org/tip/c64301a230a64dfc2fcf4581cd98a2d703f3c057
Author:     Jiang Liu <[email protected]>
AuthorDate: Mon, 1 Jun 2015 16:05:23 +0800
Committer:  Thomas Gleixner <[email protected]>
CommitDate: Fri, 12 Jun 2015 16:54:21 +0200

genirq: Introduce helper function irq_data_get_affinity_mask()

Introduce helper function irq_data_get_affinity_mask() and
irq_get_affinity_mask() to hide implementation details,
so we could move field 'affinity' from struct irq_data into
struct irq_common_data later.

Signed-off-by: Jiang Liu <[email protected]>
Acked-by: Russell King <[email protected]>
Cc: Konrad Rzeszutek Wilk <[email protected]>
Cc: Tony Luck <[email protected]>
Cc: Bjorn Helgaas <[email protected]>
Cc: Benjamin Herrenschmidt <[email protected]>
Cc: Randy Dunlap <[email protected]>
Cc: Yinghai Lu <[email protected]>
Cc: Borislav Petkov <[email protected]>
Cc: Jason Cooper <[email protected]>
Cc: Kevin Cernekee <[email protected]>
Cc: Arnd Bergmann <[email protected]>
Link: 
http://lkml.kernel.org/r/[email protected]
Signed-off-by: Thomas Gleixner <[email protected]>
---
 include/linux/irq.h | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/include/linux/irq.h b/include/linux/irq.h
index b3b82a5..1e0ccef 100644
--- a/include/linux/irq.h
+++ b/include/linux/irq.h
@@ -645,6 +645,18 @@ static inline int irq_data_get_node(struct irq_data *d)
        return d->node;
 }
 
+static inline struct cpumask *irq_get_affinity_mask(int irq)
+{
+       struct irq_data *d = irq_get_irq_data(irq);
+
+       return d ? d->affinity : NULL;
+}
+
+static inline struct cpumask *irq_data_get_affinity_mask(struct irq_data *d)
+{
+       return d->affinity;
+}
+
 unsigned int arch_dynirq_lower_bound(unsigned int from);
 
 int __irq_alloc_descs(int irq, unsigned int from, unsigned int cnt, int node,
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to