From f230b6d5c48f8d12f4dfa1f8b5ab0b0320076d21 Mon Sep 17 00:00:00 2001 From: Thomas Gleixner Date: Sat, 5 Feb 2011 15:20:04 +0100 Subject: genirq: Add IRQ_MOVE_PENDING to irq_data.state chip implementations need to know about it. Keep status in sync until all users are fixed. Accessor function: irqd_is_setaffinity_pending(irqdata) Coders who access them directly will be tracked down and slapped with stinking trouts. Signed-off-by: Thomas Gleixner --- include/linux/irq.h | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) (limited to 'include/linux') diff --git a/include/linux/irq.h b/include/linux/irq.h index 62bb08e4af13..2899905bfac7 100644 --- a/include/linux/irq.h +++ b/include/linux/irq.h @@ -58,15 +58,16 @@ typedef void (*irq_flow_handler_t)(unsigned int irq, #define IRQ_DISABLED 0x00000800 /* DEPRECATED */ #define IRQ_PENDING 0x00001000 /* DEPRECATED */ #define IRQ_MASKED 0x00002000 /* DEPRECATED */ +/* DEPRECATED use irq_setaffinity_pending() instead*/ +#define IRQ_MOVE_PENDING 0x00004000 #endif -#define IRQ_LEVEL 0x00004000 /* IRQ level triggered */ +#define IRQ_LEVEL 0x00008000 /* IRQ level triggered */ #define IRQ_PER_CPU 0x00010000 /* IRQ is per CPU */ #define IRQ_NOPROBE 0x00020000 /* IRQ is not valid for probing */ #define IRQ_NOREQUEST 0x00040000 /* IRQ cannot be requested */ #define IRQ_NOAUTOEN 0x00080000 /* IRQ will not be enabled on request irq */ #define IRQ_WAKEUP 0x00100000 /* IRQ triggers system wakeup */ -#define IRQ_MOVE_PENDING 0x00200000 /* need to re-target IRQ destination */ #define IRQ_NO_BALANCING 0x00400000 /* IRQ is excluded from balancing */ #define IRQ_MOVE_PCNTXT 0x01000000 /* IRQ migration from process context */ #define IRQ_AFFINITY_SET 0x02000000 /* IRQ affinity was set from userspace*/ @@ -128,6 +129,21 @@ struct irq_data { #endif }; +/* + * Bit masks for irq_data.state + * + * IRQD_SETAFFINITY_PENDING - Affinity setting is pending + */ +enum { + /* Bit 0 - 7 reserved for TYPE will use later */ + IRQD_SETAFFINITY_PENDING = (1 << 8), +}; + +static inline bool irqd_is_setaffinity_pending(struct irq_data *d) +{ + return d->state_use_accessors & IRQD_SETAFFINITY_PENDING; +} + /** * struct irq_chip - hardware interrupt chip descriptor * -- cgit v1.2.1