aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/sysdev/ipic.c
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2011-05-04 01:02:15 -0400
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2011-05-04 01:02:15 -0400
commit476eb4912601a8c01e6702b9a029f476b4b131d2 (patch)
tree2ed0b8c166c7cb46174318fe187f5edc062829be /arch/powerpc/sysdev/ipic.c
parent65f47f1339dfcffcd5837a307172fb41aa39e479 (diff)
powerpc/irq: Stop exporting irq_map
First step in eliminating irq_map[] table entirely Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/sysdev/ipic.c')
-rw-r--r--arch/powerpc/sysdev/ipic.c16
1 files changed, 7 insertions, 9 deletions
diff --git a/arch/powerpc/sysdev/ipic.c b/arch/powerpc/sysdev/ipic.c
index fa438be962b7..f0ece79f9be5 100644
--- a/arch/powerpc/sysdev/ipic.c
+++ b/arch/powerpc/sysdev/ipic.c
@@ -521,12 +521,10 @@ static inline struct ipic * ipic_from_irq(unsigned int virq)
521 return primary_ipic; 521 return primary_ipic;
522} 522}
523 523
524#define ipic_irq_to_hw(virq) ((unsigned int)irq_map[virq].hwirq)
525
526static void ipic_unmask_irq(struct irq_data *d) 524static void ipic_unmask_irq(struct irq_data *d)
527{ 525{
528 struct ipic *ipic = ipic_from_irq(d->irq); 526 struct ipic *ipic = ipic_from_irq(d->irq);
529 unsigned int src = ipic_irq_to_hw(d->irq); 527 unsigned int src = irqd_to_hwirq(d);
530 unsigned long flags; 528 unsigned long flags;
531 u32 temp; 529 u32 temp;
532 530
@@ -542,7 +540,7 @@ static void ipic_unmask_irq(struct irq_data *d)
542static void ipic_mask_irq(struct irq_data *d) 540static void ipic_mask_irq(struct irq_data *d)
543{ 541{
544 struct ipic *ipic = ipic_from_irq(d->irq); 542 struct ipic *ipic = ipic_from_irq(d->irq);
545 unsigned int src = ipic_irq_to_hw(d->irq); 543 unsigned int src = irqd_to_hwirq(d);
546 unsigned long flags; 544 unsigned long flags;
547 u32 temp; 545 u32 temp;
548 546
@@ -562,7 +560,7 @@ static void ipic_mask_irq(struct irq_data *d)
562static void ipic_ack_irq(struct irq_data *d) 560static void ipic_ack_irq(struct irq_data *d)
563{ 561{
564 struct ipic *ipic = ipic_from_irq(d->irq); 562 struct ipic *ipic = ipic_from_irq(d->irq);
565 unsigned int src = ipic_irq_to_hw(d->irq); 563 unsigned int src = irqd_to_hwirq(d);
566 unsigned long flags; 564 unsigned long flags;
567 u32 temp; 565 u32 temp;
568 566
@@ -581,7 +579,7 @@ static void ipic_ack_irq(struct irq_data *d)
581static void ipic_mask_irq_and_ack(struct irq_data *d) 579static void ipic_mask_irq_and_ack(struct irq_data *d)
582{ 580{
583 struct ipic *ipic = ipic_from_irq(d->irq); 581 struct ipic *ipic = ipic_from_irq(d->irq);
584 unsigned int src = ipic_irq_to_hw(d->irq); 582 unsigned int src = irqd_to_hwirq(d);
585 unsigned long flags; 583 unsigned long flags;
586 u32 temp; 584 u32 temp;
587 585
@@ -604,7 +602,7 @@ static void ipic_mask_irq_and_ack(struct irq_data *d)
604static int ipic_set_irq_type(struct irq_data *d, unsigned int flow_type) 602static int ipic_set_irq_type(struct irq_data *d, unsigned int flow_type)
605{ 603{
606 struct ipic *ipic = ipic_from_irq(d->irq); 604 struct ipic *ipic = ipic_from_irq(d->irq);
607 unsigned int src = ipic_irq_to_hw(d->irq); 605 unsigned int src = irqd_to_hwirq(d);
608 unsigned int vold, vnew, edibit; 606 unsigned int vold, vnew, edibit;
609 607
610 if (flow_type == IRQ_TYPE_NONE) 608 if (flow_type == IRQ_TYPE_NONE)
@@ -793,7 +791,7 @@ struct ipic * __init ipic_init(struct device_node *node, unsigned int flags)
793int ipic_set_priority(unsigned int virq, unsigned int priority) 791int ipic_set_priority(unsigned int virq, unsigned int priority)
794{ 792{
795 struct ipic *ipic = ipic_from_irq(virq); 793 struct ipic *ipic = ipic_from_irq(virq);
796 unsigned int src = ipic_irq_to_hw(virq); 794 unsigned int src = virq_to_hw(virq);
797 u32 temp; 795 u32 temp;
798 796
799 if (priority > 7) 797 if (priority > 7)
@@ -821,7 +819,7 @@ int ipic_set_priority(unsigned int virq, unsigned int priority)
821void ipic_set_highest_priority(unsigned int virq) 819void ipic_set_highest_priority(unsigned int virq)
822{ 820{
823 struct ipic *ipic = ipic_from_irq(virq); 821 struct ipic *ipic = ipic_from_irq(virq);
824 unsigned int src = ipic_irq_to_hw(virq); 822 unsigned int src = virq_to_hw(virq);
825 u32 temp; 823 u32 temp;
826 824
827 temp = ipic_read(ipic->regs, IPIC_SICFR); 825 temp = ipic_read(ipic->regs, IPIC_SICFR);