diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2010-09-27 12:44:35 +0000 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2010-10-04 12:43:35 +0200 |
commit | 3876ec9ef3775d062345b3760d3271ecb8cd3fea (patch) | |
tree | 6c1cd233753fe09d48bdf107da34b4dbe4e003fc /kernel/irq/chip.c | |
parent | a77c4635915021c646cc017f22239e66d1aab4d5 (diff) | |
download | linux-3876ec9ef3775d062345b3760d3271ecb8cd3fea.tar.gz linux-3876ec9ef3775d062345b3760d3271ecb8cd3fea.tar.bz2 linux-3876ec9ef3775d062345b3760d3271ecb8cd3fea.zip |
genirq: Provide compat handling for bus_lock/bus_sync_unlock
Wrap the old chip functions for bus_lock/bus_sync_unlock until the
migration is complete and the old chip functions are removed.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Peter Zijlstra <peterz@infradead.org>
LKML-Reference: <20100927121841.842536121@linutronix.de>
Reviewed-by: H. Peter Anvin <hpa@zytor.com>
Reviewed-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/irq/chip.c')
-rw-r--r-- | kernel/irq/chip.c | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/kernel/irq/chip.c b/kernel/irq/chip.c index e0e93ff10afd..77e551d92239 100644 --- a/kernel/irq/chip.c +++ b/kernel/irq/chip.c @@ -324,6 +324,17 @@ static void default_shutdown(unsigned int irq) desc->status |= IRQ_MASKED; } +/* Temporary migration helpers */ +static void compat_bus_lock(struct irq_data *data) +{ + data->chip->bus_lock(data->irq); +} + +static void compat_bus_sync_unlock(struct irq_data *data) +{ + data->chip->bus_sync_unlock(data->irq); +} + /* * Fixup enable/disable function pointers */ @@ -346,6 +357,11 @@ void irq_chip_set_defaults(struct irq_chip *chip) chip->disable : default_shutdown; if (!chip->end) chip->end = dummy_irq_chip.end; + + if (chip->bus_lock) + chip->irq_bus_lock = compat_bus_lock; + if (chip->bus_sync_unlock) + chip->irq_bus_sync_unlock = compat_bus_sync_unlock; } static inline void mask_ack_irq(struct irq_desc *desc, int irq) @@ -687,7 +703,7 @@ __set_irq_handler(unsigned int irq, irq_flow_handler_t handle, int is_chained, desc->irq_data.chip = &dummy_irq_chip; } - chip_bus_lock(irq, desc); + chip_bus_lock(desc); raw_spin_lock_irqsave(&desc->lock, flags); /* Uninstall? */ @@ -707,7 +723,7 @@ __set_irq_handler(unsigned int irq, irq_flow_handler_t handle, int is_chained, desc->irq_data.chip->startup(irq); } raw_spin_unlock_irqrestore(&desc->lock, flags); - chip_bus_sync_unlock(irq, desc); + chip_bus_sync_unlock(desc); } EXPORT_SYMBOL_GPL(__set_irq_handler); |