aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mfd/tc6393xb.c
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2010-12-12 07:34:04 -0500
committerSamuel Ortiz <sameo@linux.intel.com>2011-01-14 06:38:03 -0500
commit01af22eb15e46488cf3de67f6d2222c2eed5f763 (patch)
tree0038c5abf10c2591f57d2f3658f0947c50a21c63 /drivers/mfd/tc6393xb.c
parenta4e7feadcc2aa5754f5ebfe67b9f07b5fddede51 (diff)
mfd: Convert tc6393xb driver to new irq_ APIs
The genirq core is being update to pass struct irq_data to irq_chip rather than an irq number to operations. Update tc6393 to the new API. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Ian Molton <ian@mnementh.co.uk> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'drivers/mfd/tc6393xb.c')
-rw-r--r--drivers/mfd/tc6393xb.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/drivers/mfd/tc6393xb.c b/drivers/mfd/tc6393xb.c
index 1ea80d8ad915..9a238633a54d 100644
--- a/drivers/mfd/tc6393xb.c
+++ b/drivers/mfd/tc6393xb.c
@@ -527,41 +527,41 @@ tc6393xb_irq(unsigned int irq, struct irq_desc *desc)
527 } 527 }
528} 528}
529 529
530static void tc6393xb_irq_ack(unsigned int irq) 530static void tc6393xb_irq_ack(struct irq_data *data)
531{ 531{
532} 532}
533 533
534static void tc6393xb_irq_mask(unsigned int irq) 534static void tc6393xb_irq_mask(struct irq_data *data)
535{ 535{
536 struct tc6393xb *tc6393xb = get_irq_chip_data(irq); 536 struct tc6393xb *tc6393xb = irq_data_get_irq_chip_data(data);
537 unsigned long flags; 537 unsigned long flags;
538 u8 imr; 538 u8 imr;
539 539
540 spin_lock_irqsave(&tc6393xb->lock, flags); 540 spin_lock_irqsave(&tc6393xb->lock, flags);
541 imr = tmio_ioread8(tc6393xb->scr + SCR_IMR); 541 imr = tmio_ioread8(tc6393xb->scr + SCR_IMR);
542 imr |= 1 << (irq - tc6393xb->irq_base); 542 imr |= 1 << (data->irq - tc6393xb->irq_base);
543 tmio_iowrite8(imr, tc6393xb->scr + SCR_IMR); 543 tmio_iowrite8(imr, tc6393xb->scr + SCR_IMR);
544 spin_unlock_irqrestore(&tc6393xb->lock, flags); 544 spin_unlock_irqrestore(&tc6393xb->lock, flags);
545} 545}
546 546
547static void tc6393xb_irq_unmask(unsigned int irq) 547static void tc6393xb_irq_unmask(struct irq_data *data)
548{ 548{
549 struct tc6393xb *tc6393xb = get_irq_chip_data(irq); 549 struct tc6393xb *tc6393xb = irq_data_get_irq_chip_data(data);
550 unsigned long flags; 550 unsigned long flags;
551 u8 imr; 551 u8 imr;
552 552
553 spin_lock_irqsave(&tc6393xb->lock, flags); 553 spin_lock_irqsave(&tc6393xb->lock, flags);
554 imr = tmio_ioread8(tc6393xb->scr + SCR_IMR); 554 imr = tmio_ioread8(tc6393xb->scr + SCR_IMR);
555 imr &= ~(1 << (irq - tc6393xb->irq_base)); 555 imr &= ~(1 << (data->irq - tc6393xb->irq_base));
556 tmio_iowrite8(imr, tc6393xb->scr + SCR_IMR); 556 tmio_iowrite8(imr, tc6393xb->scr + SCR_IMR);
557 spin_unlock_irqrestore(&tc6393xb->lock, flags); 557 spin_unlock_irqrestore(&tc6393xb->lock, flags);
558} 558}
559 559
560static struct irq_chip tc6393xb_chip = { 560static struct irq_chip tc6393xb_chip = {
561 .name = "tc6393xb", 561 .name = "tc6393xb",
562 .ack = tc6393xb_irq_ack, 562 .irq_ack = tc6393xb_irq_ack,
563 .mask = tc6393xb_irq_mask, 563 .irq_mask = tc6393xb_irq_mask,
564 .unmask = tc6393xb_irq_unmask, 564 .irq_unmask = tc6393xb_irq_unmask,
565}; 565};
566 566
567static void tc6393xb_attach_irq(struct platform_device *dev) 567static void tc6393xb_attach_irq(struct platform_device *dev)