Commit d5bb1221 authored by Thomas Gleixner's avatar Thomas Gleixner Committed by Samuel Ortiz

mfd: Cleanup irq namespace

Converted with coccinelle.
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Acked-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: default avatarSamuel Ortiz <sameo@linux.intel.com>
parent c22435a3
...@@ -470,14 +470,14 @@ static int __devinit device_irq_init(struct pm860x_chip *chip, ...@@ -470,14 +470,14 @@ static int __devinit device_irq_init(struct pm860x_chip *chip,
/* register IRQ by genirq */ /* register IRQ by genirq */
for (i = 0; i < ARRAY_SIZE(pm860x_irqs); i++) { for (i = 0; i < ARRAY_SIZE(pm860x_irqs); i++) {
__irq = i + chip->irq_base; __irq = i + chip->irq_base;
set_irq_chip_data(__irq, chip); irq_set_chip_data(__irq, chip);
set_irq_chip_and_handler(__irq, &pm860x_irq_chip, irq_set_chip_and_handler(__irq, &pm860x_irq_chip,
handle_edge_irq); handle_edge_irq);
set_irq_nested_thread(__irq, 1); irq_set_nested_thread(__irq, 1);
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(__irq, IRQF_VALID); set_irq_flags(__irq, IRQF_VALID);
#else #else
set_irq_noprobe(__irq); irq_set_noprobe(__irq);
#endif #endif
} }
......
...@@ -668,7 +668,7 @@ static int ab3550_startup_irq_enabled(struct device *dev, unsigned int irq) ...@@ -668,7 +668,7 @@ static int ab3550_startup_irq_enabled(struct device *dev, unsigned int irq)
struct ab3550_platform_data *plf_data; struct ab3550_platform_data *plf_data;
bool val; bool val;
ab = get_irq_chip_data(irq); ab = irq_get_chip_data(irq);
plf_data = ab->i2c_client[0]->dev.platform_data; plf_data = ab->i2c_client[0]->dev.platform_data;
irq -= plf_data->irq.base; irq -= plf_data->irq.base;
val = ((ab->startup_events[irq / 8] & BIT(irq % 8)) != 0); val = ((ab->startup_events[irq / 8] & BIT(irq % 8)) != 0);
...@@ -1296,14 +1296,14 @@ static int __init ab3550_probe(struct i2c_client *client, ...@@ -1296,14 +1296,14 @@ static int __init ab3550_probe(struct i2c_client *client,
unsigned int irq; unsigned int irq;
irq = ab3550_plf_data->irq.base + i; irq = ab3550_plf_data->irq.base + i;
set_irq_chip_data(irq, ab); irq_set_chip_data(irq, ab);
set_irq_chip_and_handler(irq, &ab3550_irq_chip, irq_set_chip_and_handler(irq, &ab3550_irq_chip,
handle_simple_irq); handle_simple_irq);
set_irq_nested_thread(irq, 1); irq_set_nested_thread(irq, 1);
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(irq, IRQF_VALID); set_irq_flags(irq, IRQF_VALID);
#else #else
set_irq_noprobe(irq); irq_set_noprobe(irq);
#endif #endif
} }
......
...@@ -334,14 +334,14 @@ static int ab8500_irq_init(struct ab8500 *ab8500) ...@@ -334,14 +334,14 @@ static int ab8500_irq_init(struct ab8500 *ab8500)
int irq; int irq;
for (irq = base; irq < base + AB8500_NR_IRQS; irq++) { for (irq = base; irq < base + AB8500_NR_IRQS; irq++) {
set_irq_chip_data(irq, ab8500); irq_set_chip_data(irq, ab8500);
set_irq_chip_and_handler(irq, &ab8500_irq_chip, irq_set_chip_and_handler(irq, &ab8500_irq_chip,
handle_simple_irq); handle_simple_irq);
set_irq_nested_thread(irq, 1); irq_set_nested_thread(irq, 1);
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(irq, IRQF_VALID); set_irq_flags(irq, IRQF_VALID);
#else #else
set_irq_noprobe(irq); irq_set_noprobe(irq);
#endif #endif
} }
...@@ -357,8 +357,8 @@ static void ab8500_irq_remove(struct ab8500 *ab8500) ...@@ -357,8 +357,8 @@ static void ab8500_irq_remove(struct ab8500 *ab8500)
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(irq, 0); set_irq_flags(irq, 0);
#endif #endif
set_irq_chip_and_handler(irq, NULL, NULL); irq_set_chip_and_handler(irq, NULL, NULL);
set_irq_chip_data(irq, NULL); irq_set_chip_data(irq, NULL);
} }
} }
......
...@@ -388,21 +388,21 @@ static int __init asic3_irq_probe(struct platform_device *pdev) ...@@ -388,21 +388,21 @@ static int __init asic3_irq_probe(struct platform_device *pdev)
for (irq = irq_base; irq < irq_base + ASIC3_NR_IRQS; irq++) { for (irq = irq_base; irq < irq_base + ASIC3_NR_IRQS; irq++) {
if (irq < asic->irq_base + ASIC3_NUM_GPIOS) if (irq < asic->irq_base + ASIC3_NUM_GPIOS)
set_irq_chip(irq, &asic3_gpio_irq_chip); irq_set_chip(irq, &asic3_gpio_irq_chip);
else else
set_irq_chip(irq, &asic3_irq_chip); irq_set_chip(irq, &asic3_irq_chip);
set_irq_chip_data(irq, asic); irq_set_chip_data(irq, asic);
set_irq_handler(irq, handle_level_irq); irq_set_handler(irq, handle_level_irq);
set_irq_flags(irq, IRQF_VALID | IRQF_PROBE); set_irq_flags(irq, IRQF_VALID | IRQF_PROBE);
} }
asic3_write_register(asic, ASIC3_OFFSET(INTR, INT_MASK), asic3_write_register(asic, ASIC3_OFFSET(INTR, INT_MASK),
ASIC3_INTMASK_GINTMASK); ASIC3_INTMASK_GINTMASK);
set_irq_chained_handler(asic->irq_nr, asic3_irq_demux); irq_set_chained_handler(asic->irq_nr, asic3_irq_demux);
set_irq_type(asic->irq_nr, IRQ_TYPE_EDGE_RISING); irq_set_irq_type(asic->irq_nr, IRQ_TYPE_EDGE_RISING);
set_irq_data(asic->irq_nr, asic); irq_set_handler_data(asic->irq_nr, asic);
return 0; return 0;
} }
...@@ -416,11 +416,11 @@ static void asic3_irq_remove(struct platform_device *pdev) ...@@ -416,11 +416,11 @@ static void asic3_irq_remove(struct platform_device *pdev)
for (irq = irq_base; irq < irq_base + ASIC3_NR_IRQS; irq++) { for (irq = irq_base; irq < irq_base + ASIC3_NR_IRQS; irq++) {
set_irq_flags(irq, 0); set_irq_flags(irq, 0);
set_irq_handler(irq, NULL); irq_set_handler(irq, NULL);
set_irq_chip(irq, NULL); irq_set_chip(irq, NULL);
set_irq_chip_data(irq, NULL); irq_set_chip_data(irq, NULL);
} }
set_irq_chained_handler(asic->irq_nr, NULL); irq_set_chained_handler(asic->irq_nr, NULL);
} }
/* GPIOs */ /* GPIOs */
......
...@@ -207,7 +207,7 @@ static void pcap_isr_work(struct work_struct *work) ...@@ -207,7 +207,7 @@ static void pcap_isr_work(struct work_struct *work)
static void pcap_irq_handler(unsigned int irq, struct irq_desc *desc) static void pcap_irq_handler(unsigned int irq, struct irq_desc *desc)
{ {
struct pcap_chip *pcap = get_irq_data(irq); struct pcap_chip *pcap = irq_get_handler_data(irq);
desc->irq_data.chip->irq_ack(&desc->irq_data); desc->irq_data.chip->irq_ack(&desc->irq_data);
queue_work(pcap->workqueue, &pcap->isr_work); queue_work(pcap->workqueue, &pcap->isr_work);
...@@ -411,7 +411,7 @@ static int __devexit ezx_pcap_remove(struct spi_device *spi) ...@@ -411,7 +411,7 @@ static int __devexit ezx_pcap_remove(struct spi_device *spi)
/* cleanup irqchip */ /* cleanup irqchip */
for (i = pcap->irq_base; i < (pcap->irq_base + PCAP_NIRQS); i++) for (i = pcap->irq_base; i < (pcap->irq_base + PCAP_NIRQS); i++)
set_irq_chip_and_handler(i, NULL, NULL); irq_set_chip_and_handler(i, NULL, NULL);
destroy_workqueue(pcap->workqueue); destroy_workqueue(pcap->workqueue);
...@@ -468,12 +468,12 @@ static int __devinit ezx_pcap_probe(struct spi_device *spi) ...@@ -468,12 +468,12 @@ static int __devinit ezx_pcap_probe(struct spi_device *spi)
/* setup irq chip */ /* setup irq chip */
for (i = pcap->irq_base; i < (pcap->irq_base + PCAP_NIRQS); i++) { for (i = pcap->irq_base; i < (pcap->irq_base + PCAP_NIRQS); i++) {
set_irq_chip_and_handler(i, &pcap_irq_chip, handle_simple_irq); irq_set_chip_and_handler(i, &pcap_irq_chip, handle_simple_irq);
set_irq_chip_data(i, pcap); irq_set_chip_data(i, pcap);
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(i, IRQF_VALID); set_irq_flags(i, IRQF_VALID);
#else #else
set_irq_noprobe(i); irq_set_noprobe(i);
#endif #endif
} }
...@@ -482,10 +482,10 @@ static int __devinit ezx_pcap_probe(struct spi_device *spi) ...@@ -482,10 +482,10 @@ static int __devinit ezx_pcap_probe(struct spi_device *spi)
ezx_pcap_write(pcap, PCAP_REG_ISR, PCAP_CLEAR_INTERRUPT_REGISTER); ezx_pcap_write(pcap, PCAP_REG_ISR, PCAP_CLEAR_INTERRUPT_REGISTER);
pcap->msr = PCAP_MASK_ALL_INTERRUPT; pcap->msr = PCAP_MASK_ALL_INTERRUPT;
set_irq_type(spi->irq, IRQ_TYPE_EDGE_RISING); irq_set_irq_type(spi->irq, IRQ_TYPE_EDGE_RISING);
set_irq_data(spi->irq, pcap); irq_set_handler_data(spi->irq, pcap);
set_irq_chained_handler(spi->irq, pcap_irq_handler); irq_set_chained_handler(spi->irq, pcap_irq_handler);
set_irq_wake(spi->irq, 1); irq_set_irq_wake(spi->irq, 1);
/* ADC */ /* ADC */
adc_irq = pcap_to_irq(pcap, (pdata->config & PCAP_SECOND_PORT) ? adc_irq = pcap_to_irq(pcap, (pdata->config & PCAP_SECOND_PORT) ?
...@@ -514,7 +514,7 @@ static int __devinit ezx_pcap_probe(struct spi_device *spi) ...@@ -514,7 +514,7 @@ static int __devinit ezx_pcap_probe(struct spi_device *spi)
free_irq(adc_irq, pcap); free_irq(adc_irq, pcap);
free_irqchip: free_irqchip:
for (i = pcap->irq_base; i < (pcap->irq_base + PCAP_NIRQS); i++) for (i = pcap->irq_base; i < (pcap->irq_base + PCAP_NIRQS); i++)
set_irq_chip_and_handler(i, NULL, NULL); irq_set_chip_and_handler(i, NULL, NULL);
/* destroy_workqueue: */ /* destroy_workqueue: */
destroy_workqueue(pcap->workqueue); destroy_workqueue(pcap->workqueue);
free_pcap: free_pcap:
......
...@@ -344,14 +344,14 @@ static int __init egpio_probe(struct platform_device *pdev) ...@@ -344,14 +344,14 @@ static int __init egpio_probe(struct platform_device *pdev)
ei->ack_write = 0; ei->ack_write = 0;
irq_end = ei->irq_start + ei->nirqs; irq_end = ei->irq_start + ei->nirqs;
for (irq = ei->irq_start; irq < irq_end; irq++) { for (irq = ei->irq_start; irq < irq_end; irq++) {
set_irq_chip(irq, &egpio_muxed_chip); irq_set_chip(irq, &egpio_muxed_chip);
set_irq_chip_data(irq, ei); irq_set_chip_data(irq, ei);
set_irq_handler(irq, handle_simple_irq); irq_set_handler(irq, handle_simple_irq);
set_irq_flags(irq, IRQF_VALID | IRQF_PROBE); set_irq_flags(irq, IRQF_VALID | IRQF_PROBE);
} }
set_irq_type(ei->chained_irq, IRQ_TYPE_EDGE_RISING); irq_set_irq_type(ei->chained_irq, IRQ_TYPE_EDGE_RISING);
set_irq_data(ei->chained_irq, ei); irq_set_handler_data(ei->chained_irq, ei);
set_irq_chained_handler(ei->chained_irq, egpio_handler); irq_set_chained_handler(ei->chained_irq, egpio_handler);
ack_irqs(ei); ack_irqs(ei);
device_init_wakeup(&pdev->dev, 1); device_init_wakeup(&pdev->dev, 1);
...@@ -373,11 +373,11 @@ static int __exit egpio_remove(struct platform_device *pdev) ...@@ -373,11 +373,11 @@ static int __exit egpio_remove(struct platform_device *pdev)
if (ei->chained_irq) { if (ei->chained_irq) {
irq_end = ei->irq_start + ei->nirqs; irq_end = ei->irq_start + ei->nirqs;
for (irq = ei->irq_start; irq < irq_end; irq++) { for (irq = ei->irq_start; irq < irq_end; irq++) {
set_irq_chip(irq, NULL); irq_set_chip(irq, NULL);
set_irq_handler(irq, NULL); irq_set_handler(irq, NULL);
set_irq_flags(irq, 0); set_irq_flags(irq, 0);
} }
set_irq_chained_handler(ei->chained_irq, NULL); irq_set_chained_handler(ei->chained_irq, NULL);
device_init_wakeup(&pdev->dev, 0); device_init_wakeup(&pdev->dev, 0);
} }
iounmap(ei->base_addr); iounmap(ei->base_addr);
......
...@@ -348,13 +348,13 @@ static int __devinit htcpld_setup_chip_irq( ...@@ -348,13 +348,13 @@ static int __devinit htcpld_setup_chip_irq(
/* Setup irq handlers */ /* Setup irq handlers */
irq_end = chip->irq_start + chip->nirqs; irq_end = chip->irq_start + chip->nirqs;
for (irq = chip->irq_start; irq < irq_end; irq++) { for (irq = chip->irq_start; irq < irq_end; irq++) {
set_irq_chip(irq, &htcpld_muxed_chip); irq_set_chip(irq, &htcpld_muxed_chip);
set_irq_chip_data(irq, chip); irq_set_chip_data(irq, chip);
set_irq_handler(irq, handle_simple_irq); irq_set_handler(irq, handle_simple_irq);
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(irq, IRQF_VALID | IRQF_PROBE); set_irq_flags(irq, IRQF_VALID | IRQF_PROBE);
#else #else
set_irq_probe(irq); irq_set_probe(irq);
#endif #endif
} }
......
...@@ -112,7 +112,7 @@ static struct irq_chip jz4740_adc_irq_chip = { ...@@ -112,7 +112,7 @@ static struct irq_chip jz4740_adc_irq_chip = {
static void jz4740_adc_irq_demux(unsigned int irq, struct irq_desc *desc) static void jz4740_adc_irq_demux(unsigned int irq, struct irq_desc *desc)
{ {
struct jz4740_adc *adc = get_irq_desc_data(desc); struct jz4740_adc *adc = irq_desc_get_handler_data(desc);
uint8_t status; uint8_t status;
unsigned int i; unsigned int i;
...@@ -310,13 +310,13 @@ static int __devinit jz4740_adc_probe(struct platform_device *pdev) ...@@ -310,13 +310,13 @@ static int __devinit jz4740_adc_probe(struct platform_device *pdev)
platform_set_drvdata(pdev, adc); platform_set_drvdata(pdev, adc);
for (irq = adc->irq_base; irq < adc->irq_base + 5; ++irq) { for (irq = adc->irq_base; irq < adc->irq_base + 5; ++irq) {
set_irq_chip_data(irq, adc); irq_set_chip_data(irq, adc);
set_irq_chip_and_handler(irq, &jz4740_adc_irq_chip, irq_set_chip_and_handler(irq, &jz4740_adc_irq_chip,
handle_level_irq); handle_level_irq);
} }
set_irq_data(adc->irq, adc); irq_set_handler_data(adc->irq, adc);
set_irq_chained_handler(adc->irq, jz4740_adc_irq_demux); irq_set_chained_handler(adc->irq, jz4740_adc_irq_demux);
writeb(0x00, adc->base + JZ_REG_ADC_ENABLE); writeb(0x00, adc->base + JZ_REG_ADC_ENABLE);
writeb(0xff, adc->base + JZ_REG_ADC_CTRL); writeb(0xff, adc->base + JZ_REG_ADC_CTRL);
...@@ -347,8 +347,8 @@ static int __devexit jz4740_adc_remove(struct platform_device *pdev) ...@@ -347,8 +347,8 @@ static int __devexit jz4740_adc_remove(struct platform_device *pdev)
mfd_remove_devices(&pdev->dev); mfd_remove_devices(&pdev->dev);
set_irq_data(adc->irq, NULL); irq_set_handler_data(adc->irq, NULL);
set_irq_chained_handler(adc->irq, NULL); irq_set_chained_handler(adc->irq, NULL);
iounmap(adc->base); iounmap(adc->base);
release_mem_region(adc->mem->start, resource_size(adc->mem)); release_mem_region(adc->mem->start, resource_size(adc->mem));
......
...@@ -547,14 +547,14 @@ static int max8925_irq_init(struct max8925_chip *chip, int irq, ...@@ -547,14 +547,14 @@ static int max8925_irq_init(struct max8925_chip *chip, int irq,
/* register with genirq */ /* register with genirq */
for (i = 0; i < ARRAY_SIZE(max8925_irqs); i++) { for (i = 0; i < ARRAY_SIZE(max8925_irqs); i++) {
__irq = i + chip->irq_base; __irq = i + chip->irq_base;
set_irq_chip_data(__irq, chip); irq_set_chip_data(__irq, chip);
set_irq_chip_and_handler(__irq, &max8925_irq_chip, irq_set_chip_and_handler(__irq, &max8925_irq_chip,
handle_edge_irq); handle_edge_irq);
set_irq_nested_thread(__irq, 1); irq_set_nested_thread(__irq, 1);
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(__irq, IRQF_VALID); set_irq_flags(__irq, IRQF_VALID);
#else #else
set_irq_noprobe(__irq); irq_set_noprobe(__irq);
#endif #endif
} }
if (!irq) { if (!irq) {
......
...@@ -224,14 +224,14 @@ int max8998_irq_init(struct max8998_dev *max8998) ...@@ -224,14 +224,14 @@ int max8998_irq_init(struct max8998_dev *max8998)
/* register with genirq */ /* register with genirq */
for (i = 0; i < MAX8998_IRQ_NR; i++) { for (i = 0; i < MAX8998_IRQ_NR; i++) {
cur_irq = i + max8998->irq_base; cur_irq = i + max8998->irq_base;
set_irq_chip_data(cur_irq, max8998); irq_set_chip_data(cur_irq, max8998);
set_irq_chip_and_handler(cur_irq, &max8998_irq_chip, irq_set_chip_and_handler(cur_irq, &max8998_irq_chip,
handle_edge_irq); handle_edge_irq);
set_irq_nested_thread(cur_irq, 1); irq_set_nested_thread(cur_irq, 1);
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(cur_irq, IRQF_VALID); set_irq_flags(cur_irq, IRQF_VALID);
#else #else
set_irq_noprobe(cur_irq); irq_set_noprobe(cur_irq);
#endif #endif
} }
......
...@@ -209,7 +209,7 @@ static int max8998_suspend(struct device *dev) ...@@ -209,7 +209,7 @@ static int max8998_suspend(struct device *dev)
struct max8998_dev *max8998 = i2c_get_clientdata(i2c); struct max8998_dev *max8998 = i2c_get_clientdata(i2c);
if (max8998->wakeup) if (max8998->wakeup)
set_irq_wake(max8998->irq, 1); irq_set_irq_wake(max8998->irq, 1);
return 0; return 0;
} }
...@@ -219,7 +219,7 @@ static int max8998_resume(struct device *dev) ...@@ -219,7 +219,7 @@ static int max8998_resume(struct device *dev)
struct max8998_dev *max8998 = i2c_get_clientdata(i2c); struct max8998_dev *max8998 = i2c_get_clientdata(i2c);
if (max8998->wakeup) if (max8998->wakeup)
set_irq_wake(max8998->irq, 0); irq_set_irq_wake(max8998->irq, 0);
/* /*
* In LP3974, if IRQ registers are not "read & clear" * In LP3974, if IRQ registers are not "read & clear"
* when it's set during sleep, the interrupt becomes * when it's set during sleep, the interrupt becomes
......
...@@ -762,14 +762,14 @@ static int __devinit stmpe_irq_init(struct stmpe *stmpe) ...@@ -762,14 +762,14 @@ static int __devinit stmpe_irq_init(struct stmpe *stmpe)
int irq; int irq;
for (irq = base; irq < base + num_irqs; irq++) { for (irq = base; irq < base + num_irqs; irq++) {
set_irq_chip_data(irq, stmpe); irq_set_chip_data(irq, stmpe);
set_irq_chip_and_handler(irq, &stmpe_irq_chip, irq_set_chip_and_handler(irq, &stmpe_irq_chip,
handle_edge_irq); handle_edge_irq);
set_irq_nested_thread(irq, 1); irq_set_nested_thread(irq, 1);
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(irq, IRQF_VALID); set_irq_flags(irq, IRQF_VALID);
#else #else
set_irq_noprobe(irq); irq_set_noprobe(irq);
#endif #endif
} }
...@@ -786,8 +786,8 @@ static void stmpe_irq_remove(struct stmpe *stmpe) ...@@ -786,8 +786,8 @@ static void stmpe_irq_remove(struct stmpe *stmpe)
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(irq, 0); set_irq_flags(irq, 0);
#endif #endif
set_irq_chip_and_handler(irq, NULL, NULL); irq_set_chip_and_handler(irq, NULL, NULL);
set_irq_chip_data(irq, NULL); irq_set_chip_data(irq, NULL);
} }
} }
......
...@@ -186,7 +186,7 @@ static struct mfd_cell t7l66xb_cells[] = { ...@@ -186,7 +186,7 @@ static struct mfd_cell t7l66xb_cells[] = {
/* Handle the T7L66XB interrupt mux */ /* Handle the T7L66XB interrupt mux */
static void t7l66xb_irq(unsigned int irq, struct irq_desc *desc) static void t7l66xb_irq(unsigned int irq, struct irq_desc *desc)
{ {
struct t7l66xb *t7l66xb = get_irq_data(irq); struct t7l66xb *t7l66xb = irq_get_handler_data(irq);
unsigned int isr; unsigned int isr;
unsigned int i, irq_base; unsigned int i, irq_base;
...@@ -243,17 +243,17 @@ static void t7l66xb_attach_irq(struct platform_device *dev) ...@@ -243,17 +243,17 @@ static void t7l66xb_attach_irq(struct platform_device *dev)
irq_base = t7l66xb->irq_base; irq_base = t7l66xb->irq_base;
for (irq = irq_base; irq < irq_base + T7L66XB_NR_IRQS; irq++) { for (irq = irq_base; irq < irq_base + T7L66XB_NR_IRQS; irq++) {
set_irq_chip(irq, &t7l66xb_chip); irq_set_chip(irq, &t7l66xb_chip);
set_irq_chip_data(irq, t7l66xb); irq_set_chip_data(irq, t7l66xb);
set_irq_handler(irq, handle_level_irq); irq_set_handler(irq, handle_level_irq);
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(irq, IRQF_VALID | IRQF_PROBE); set_irq_flags(irq, IRQF_VALID | IRQF_PROBE);
#endif #endif
} }
set_irq_type(t7l66xb->irq, IRQ_TYPE_EDGE_FALLING); irq_set_irq_type(t7l66xb->irq, IRQ_TYPE_EDGE_FALLING);
set_irq_data(t7l66xb->irq, t7l66xb); irq_set_handler_data(t7l66xb->irq, t7l66xb);
set_irq_chained_handler(t7l66xb->irq, t7l66xb_irq); irq_set_chained_handler(t7l66xb->irq, t7l66xb_irq);
} }
static void t7l66xb_detach_irq(struct platform_device *dev) static void t7l66xb_detach_irq(struct platform_device *dev)
...@@ -263,15 +263,15 @@ static void t7l66xb_detach_irq(struct platform_device *dev) ...@@ -263,15 +263,15 @@ static void t7l66xb_detach_irq(struct platform_device *dev)
irq_base = t7l66xb->irq_base; irq_base = t7l66xb->irq_base;
set_irq_chained_handler(t7l66xb->irq, NULL); irq_set_chained_handler(t7l66xb->irq, NULL);
set_irq_data(t7l66xb->irq, NULL); irq_set_handler_data(t7l66xb->irq, NULL);
for (irq = irq_base; irq < irq_base + T7L66XB_NR_IRQS; irq++) { for (irq = irq_base; irq < irq_base + T7L66XB_NR_IRQS; irq++) {
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(irq, 0); set_irq_flags(irq, 0);
#endif #endif
set_irq_chip(irq, NULL); irq_set_chip(irq, NULL);
set_irq_chip_data(irq, NULL); irq_set_chip_data(irq, NULL);
} }
} }
......
...@@ -192,14 +192,14 @@ static int tc3589x_irq_init(struct tc3589x *tc3589x) ...@@ -192,14 +192,14 @@ static int tc3589x_irq_init(struct tc3589x *tc3589x)
int irq; int irq;
for (irq = base; irq < base + TC3589x_NR_INTERNAL_IRQS; irq++) { for (irq = base; irq < base + TC3589x_NR_INTERNAL_IRQS; irq++) {
set_irq_chip_data(irq, tc3589x); irq_set_chip_data(irq, tc3589x);
set_irq_chip_and_handler(irq, &dummy_irq_chip, irq_set_chip_and_handler(irq, &dummy_irq_chip,
handle_edge_irq); handle_edge_irq);
set_irq_nested_thread(irq, 1); irq_set_nested_thread(irq, 1);
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(irq, IRQF_VALID); set_irq_flags(irq, IRQF_VALID);
#else #else
set_irq_noprobe(irq); irq_set_noprobe(irq);
#endif #endif
} }
...@@ -215,8 +215,8 @@ static void tc3589x_irq_remove(struct tc3589x *tc3589x) ...@@ -215,8 +215,8 @@ static void tc3589x_irq_remove(struct tc3589x *tc3589x)
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(irq, 0); set_irq_flags(irq, 0);
#endif #endif
set_irq_chip_and_handler(irq, NULL, NULL); irq_set_chip_and_handler(irq, NULL, NULL);
set_irq_chip_data(irq, NULL); irq_set_chip_data(irq, NULL);
} }
} }
......
...@@ -513,7 +513,7 @@ static int tc6393xb_register_gpio(struct tc6393xb *tc6393xb, int gpio_base) ...@@ -513,7 +513,7 @@ static int tc6393xb_register_gpio(struct tc6393xb *tc6393xb, int gpio_base)
static void static void
tc6393xb_irq(unsigned int irq, struct irq_desc *desc) tc6393xb_irq(unsigned int irq, struct irq_desc *desc)
{ {
struct tc6393xb *tc6393xb = get_irq_data(irq); struct tc6393xb *tc6393xb = irq_get_handler_data(irq);
unsigned int isr; unsigned int isr;
unsigned int i, irq_base; unsigned int i, irq_base;
...@@ -572,15 +572,15 @@ static void tc6393xb_attach_irq(struct platform_device *dev) ...@@ -572,15 +572,15 @@ static void tc6393xb_attach_irq(struct platform_device *dev)
irq_base = tc6393xb->irq_base; irq_base = tc6393xb->irq_base;
for (irq = irq_base; irq < irq_base + TC6393XB_NR_IRQS; irq++) { for (irq = irq_base; irq < irq_base + TC6393XB_NR_IRQS; irq++) {
set_irq_chip(irq, &tc6393xb_chip); irq_set_chip(irq, &tc6393xb_chip);
set_irq_chip_data(irq, tc6393xb); irq_set_chip_data(irq, tc6393xb);
set_irq_handler(irq, handle_edge_irq); irq_set_handler(irq, handle_edge_irq);
set_irq_flags(irq, IRQF_VALID | IRQF_PROBE); set_irq_flags(irq, IRQF_VALID | IRQF_PROBE);
} }
set_irq_type(tc6393xb->irq, IRQ_TYPE_EDGE_FALLING); irq_set_irq_type(tc6393xb->irq, IRQ_TYPE_EDGE_FALLING);
set_irq_data(tc6393xb->irq, tc6393xb); irq_set_handler_data(tc6393xb->irq, tc6393xb);
set_irq_chained_handler(tc6393xb->irq, tc6393xb_irq); irq_set_chained_handler(tc6393xb->irq, tc6393xb_irq);
} }
static void tc6393xb_detach_irq(struct platform_device *dev) static void tc6393xb_detach_irq(struct platform_device *dev)
...@@ -588,15 +588,15 @@ static void tc6393xb_detach_irq(struct platform_device *dev) ...@@ -588,15 +588,15 @@ static void tc6393xb_detach_irq(struct platform_device *dev)
struct tc6393xb *tc6393xb = platform_get_drvdata(dev); struct tc6393xb *tc6393xb = platform_get_drvdata(dev);
unsigned int irq, irq_base; unsigned int irq, irq_base;
set_irq_chained_handler(tc6393xb->irq, NULL); irq_set_chained_handler(tc6393xb->irq, NULL);
set_irq_data(tc6393xb->irq, NULL); irq_set_handler_data(tc6393xb->irq, NULL);
irq_base = tc6393xb->irq_base; irq_base = tc6393xb->irq_base;
for (irq = irq_base; irq < irq_base + TC6393XB_NR_IRQS; irq++) { for (irq = irq_base; irq < irq_base + TC6393XB_NR_IRQS; irq++) {
set_irq_flags(irq, 0); set_irq_flags(irq, 0);
set_irq_chip(irq, NULL); irq_set_chip(irq, NULL);
set_irq_chip_data(irq, NULL); irq_set_chip_data(irq, NULL);
} }
} }
......
...@@ -422,10 +422,10 @@ static int __devinit tps6586x_irq_init(struct tps6586x *tps6586x, int irq, ...@@ -422,10 +422,10 @@ static int __devinit tps6586x_irq_init(struct tps6586x *tps6586x, int irq,
for (i = 0; i < ARRAY_SIZE(tps6586x_irqs); i++) { for (i = 0; i < ARRAY_SIZE(tps6586x_irqs); i++) {
int __irq = i + tps6586x->irq_base; int __irq = i + tps6586x->irq_base;
set_irq_chip_data(__irq, tps6586x); irq_set_chip_data(__irq, tps6586x);
set_irq_chip_and_handler(__irq, &tps6586x->irq_chip, irq_set_chip_and_handler(__irq, &tps6586x->irq_chip,
handle_simple_irq); handle_simple_irq);
set_irq_nested_thread(__irq, 1); irq_set_nested_thread(__irq, 1);
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(__irq, IRQF_VALID); set_irq_flags(__irq, IRQF_VALID);
#endif #endif
......
...@@ -454,7 +454,7 @@ static inline void activate_irq(int irq) ...@@ -454,7 +454,7 @@ static inline void activate_irq(int irq)
set_irq_flags(irq, IRQF_VALID); set_irq_flags(irq, IRQF_VALID);
#else #else
/* same effect on other architectures */ /* same effect on other architectures */
set_irq_noprobe(irq); irq_set_noprobe(irq);
#endif #endif
} }
...@@ -650,7 +650,7 @@ static inline int sih_read_isr(const struct sih *sih) ...@@ -650,7 +650,7 @@ static inline int sih_read_isr(const struct sih *sih)
*/ */
static void handle_twl4030_sih(unsigned irq, struct irq_desc *desc) static void handle_twl4030_sih(unsigned irq, struct irq_desc *desc)
{ {
struct sih_agent *agent = get_irq_data(irq); struct sih_agent *agent = irq_get_handler_data(irq);
const struct sih *sih = agent->sih; const struct sih *sih = agent->sih;
int isr; int isr;
...@@ -724,9 +724,9 @@ int twl4030_sih_setup(int module) ...@@ -724,9 +724,9 @@ int twl4030_sih_setup(int module)
for (i = 0; i < sih->bits; i++) { for (i = 0; i < sih->bits; i++) {
irq = irq_base + i; irq = irq_base + i;
set_irq_chip_and_handler(irq, &twl4030_sih_irq_chip, irq_set_chip_and_handler(irq, &twl4030_sih_irq_chip,
handle_edge_irq); handle_edge_irq);
set_irq_chip_data(irq, agent); irq_set_chip_data(irq, agent);
activate_irq(irq); activate_irq(irq);
} }
...@@ -735,8 +735,8 @@ int twl4030_sih_setup(int module) ...@@ -735,8 +735,8 @@ int twl4030_sih_setup(int module)
/* replace generic PIH handler (handle_simple_irq) */ /* replace generic PIH handler (handle_simple_irq) */
irq = sih_mod + twl4030_irq_base; irq = sih_mod + twl4030_irq_base;
set_irq_data(irq, agent); irq_set_handler_data(irq, agent);
set_irq_chained_handler(irq, handle_twl4030_sih); irq_set_chained_handler(irq, handle_twl4030_sih);
pr_info("twl4030: %s (irq %d) chaining IRQs %d..%d\n", sih->name, pr_info("twl4030: %s (irq %d) chaining IRQs %d..%d\n", sih->name,
irq, irq_base, twl4030_irq_next - 1); irq, irq_base, twl4030_irq_next - 1);
...@@ -785,8 +785,8 @@ int twl4030_init_irq(int irq_num, unsigned irq_base, unsigned irq_end) ...@@ -785,8 +785,8 @@ int twl4030_init_irq(int irq_num, unsigned irq_base, unsigned irq_end)
twl4030_sih_irq_chip.irq_ack = dummy_irq_chip.irq_ack; twl4030_sih_irq_chip.irq_ack = dummy_irq_chip.irq_ack;
for (i = irq_base; i < irq_end; i++) { for (i = irq_base; i < irq_end; i++) {
set_irq_chip_and_handler(i, &twl4030_irq_chip, irq_set_chip_and_handler(i, &twl4030_irq_chip,
handle_simple_irq); handle_simple_irq);
activate_irq(i); activate_irq(i);
} }
twl4030_irq_next = i; twl4030_irq_next = i;
...@@ -826,7 +826,7 @@ int twl4030_init_irq(int irq_num, unsigned irq_base, unsigned irq_end) ...@@ -826,7 +826,7 @@ int twl4030_init_irq(int irq_num, unsigned irq_base, unsigned irq_end)
/* clean up twl4030_sih_setup */ /* clean up twl4030_sih_setup */
fail: fail:
for (i = irq_base; i < irq_end; i++) for (i = irq_base; i < irq_end; i++)
set_irq_chip_and_handler(i, NULL, NULL); irq_set_chip_and_handler(i, NULL, NULL);
destroy_workqueue(wq); destroy_workqueue(wq);
wq = NULL; wq = NULL;
return status; return status;
......
...@@ -183,7 +183,7 @@ static inline void activate_irq(int irq) ...@@ -183,7 +183,7 @@ static inline void activate_irq(int irq)
set_irq_flags(irq, IRQF_VALID); set_irq_flags(irq, IRQF_VALID);
#else #else
/* same effect on other architectures */ /* same effect on other architectures */
set_irq_noprobe(irq); irq_set_noprobe(irq);
#endif #endif
} }
...@@ -320,8 +320,8 @@ int twl6030_init_irq(int irq_num, unsigned irq_base, unsigned irq_end) ...@@ -320,8 +320,8 @@ int twl6030_init_irq(int irq_num, unsigned irq_base, unsigned irq_end)
twl6030_irq_chip.irq_set_type = NULL; twl6030_irq_chip.irq_set_type = NULL;
for (i = irq_base; i < irq_end; i++) { for (i = irq_base; i < irq_end; i++) {
set_irq_chip_and_handler(i, &twl6030_irq_chip, irq_set_chip_and_handler(i, &twl6030_irq_chip,
handle_simple_irq); handle_simple_irq);
activate_irq(i); activate_irq(i);
} }
...@@ -350,7 +350,7 @@ int twl6030_init_irq(int irq_num, unsigned irq_base, unsigned irq_end) ...@@ -350,7 +350,7 @@ int twl6030_init_irq(int irq_num, unsigned irq_base, unsigned irq_end)
fail_kthread: fail_kthread:
for (i = irq_base; i < irq_end; i++) for (i = irq_base; i < irq_end; i++)
set_irq_chip_and_handler(i, NULL, NULL); irq_set_chip_and_handler(i, NULL, NULL);
return status; return status;
} }
......
...@@ -553,17 +553,17 @@ int wm831x_irq_init(struct wm831x *wm831x, int irq) ...@@ -553,17 +553,17 @@ int wm831x_irq_init(struct wm831x *wm831x, int irq)
for (cur_irq = wm831x->irq_base; for (cur_irq = wm831x->irq_base;
cur_irq < ARRAY_SIZE(wm831x_irqs) + wm831x->irq_base; cur_irq < ARRAY_SIZE(wm831x_irqs) + wm831x->irq_base;
cur_irq++) { cur_irq++) {
set_irq_chip_data(cur_irq, wm831x); irq_set_chip_data(cur_irq, wm831x);
set_irq_chip_and_handler(cur_irq, &wm831x_irq_chip, irq_set_chip_and_handler(cur_irq, &wm831x_irq_chip,
handle_edge_irq); handle_edge_irq);
set_irq_nested_thread(cur_irq, 1); irq_set_nested_thread(cur_irq, 1);
/* ARM needs us to explicitly flag the IRQ as valid /* ARM needs us to explicitly flag the IRQ as valid
* and will set them noprobe when we do so. */ * and will set them noprobe when we do so. */
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(cur_irq, IRQF_VALID); set_irq_flags(cur_irq, IRQF_VALID);
#else #else
set_irq_noprobe(cur_irq); irq_set_noprobe(cur_irq);
#endif #endif
} }
......
...@@ -518,17 +518,17 @@ int wm8350_irq_init(struct wm8350 *wm8350, int irq, ...@@ -518,17 +518,17 @@ int wm8350_irq_init(struct wm8350 *wm8350, int irq,
for (cur_irq = wm8350->irq_base; for (cur_irq = wm8350->irq_base;
cur_irq < ARRAY_SIZE(wm8350_irqs) + wm8350->irq_base; cur_irq < ARRAY_SIZE(wm8350_irqs) + wm8350->irq_base;
cur_irq++) { cur_irq++) {
set_irq_chip_data(cur_irq, wm8350); irq_set_chip_data(cur_irq, wm8350);
set_irq_chip_and_handler(cur_irq, &wm8350_irq_chip, irq_set_chip_and_handler(cur_irq, &wm8350_irq_chip,
handle_edge_irq); handle_edge_irq);
set_irq_nested_thread(cur_irq, 1); irq_set_nested_thread(cur_irq, 1);
/* ARM needs us to explicitly flag the IRQ as valid /* ARM needs us to explicitly flag the IRQ as valid
* and will set them noprobe when we do so. */ * and will set them noprobe when we do so. */
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(cur_irq, IRQF_VALID); set_irq_flags(cur_irq, IRQF_VALID);
#else #else
set_irq_noprobe(cur_irq); irq_set_noprobe(cur_irq);
#endif #endif
} }
......
...@@ -278,17 +278,17 @@ int wm8994_irq_init(struct wm8994 *wm8994) ...@@ -278,17 +278,17 @@ int wm8994_irq_init(struct wm8994 *wm8994)
for (cur_irq = wm8994->irq_base; for (cur_irq = wm8994->irq_base;
cur_irq < ARRAY_SIZE(wm8994_irqs) + wm8994->irq_base; cur_irq < ARRAY_SIZE(wm8994_irqs) + wm8994->irq_base;
cur_irq++) { cur_irq++) {
set_irq_chip_data(cur_irq, wm8994); irq_set_chip_data(cur_irq, wm8994);
set_irq_chip_and_handler(cur_irq, &wm8994_irq_chip, irq_set_chip_and_handler(cur_irq, &wm8994_irq_chip,
handle_edge_irq); handle_edge_irq);
set_irq_nested_thread(cur_irq, 1); irq_set_nested_thread(cur_irq, 1);
/* ARM needs us to explicitly flag the IRQ as valid /* ARM needs us to explicitly flag the IRQ as valid
* and will set them noprobe when we do so. */ * and will set them noprobe when we do so. */
#ifdef CONFIG_ARM #ifdef CONFIG_ARM
set_irq_flags(cur_irq, IRQF_VALID); set_irq_flags(cur_irq, IRQF_VALID);
#else #else
set_irq_noprobe(cur_irq); irq_set_noprobe(cur_irq);
#endif #endif
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment