diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/powerpc/platforms/86xx/mpc86xx_hpcn.c | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/arch/powerpc/platforms/86xx/mpc86xx_hpcn.c b/arch/powerpc/platforms/86xx/mpc86xx_hpcn.c index 813eb5811eb4..0b1b52168bb7 100644 --- a/arch/powerpc/platforms/86xx/mpc86xx_hpcn.c +++ b/arch/powerpc/platforms/86xx/mpc86xx_hpcn.c | |||
@@ -68,37 +68,36 @@ mpc86xx_hpcn_init_irq(void) | |||
68 | { | 68 | { |
69 | struct mpic *mpic1; | 69 | struct mpic *mpic1; |
70 | struct device_node *np; | 70 | struct device_node *np; |
71 | phys_addr_t openpic_paddr; | 71 | struct resource res; |
72 | #ifdef CONFIG_PCI | 72 | #ifdef CONFIG_PCI |
73 | struct device_node *cascade_node = NULL; | 73 | struct device_node *cascade_node = NULL; |
74 | int cascade_irq; | 74 | int cascade_irq; |
75 | #endif | 75 | #endif |
76 | 76 | ||
77 | /* Determine PIC address. */ | ||
77 | np = of_find_node_by_type(NULL, "open-pic"); | 78 | np = of_find_node_by_type(NULL, "open-pic"); |
78 | if (np == NULL) | 79 | if (np == NULL) |
79 | return; | 80 | return; |
80 | 81 | of_address_to_resource(np, 0, &res); | |
81 | /* Determine the Physical Address of the OpenPIC regs */ | ||
82 | openpic_paddr = get_immrbase() + MPC86xx_OPENPIC_OFFSET; | ||
83 | 82 | ||
84 | /* Alloc mpic structure and per isu has 16 INT entries. */ | 83 | /* Alloc mpic structure and per isu has 16 INT entries. */ |
85 | mpic1 = mpic_alloc(np, openpic_paddr, | 84 | mpic1 = mpic_alloc(np, res.start, |
86 | MPIC_PRIMARY | MPIC_WANTS_RESET | MPIC_BIG_ENDIAN, | 85 | MPIC_PRIMARY | MPIC_WANTS_RESET | MPIC_BIG_ENDIAN, |
87 | 16, NR_IRQS - 4, | 86 | 16, NR_IRQS - 4, |
88 | " MPIC "); | 87 | " MPIC "); |
89 | BUG_ON(mpic1 == NULL); | 88 | BUG_ON(mpic1 == NULL); |
90 | 89 | ||
91 | mpic_assign_isu(mpic1, 0, openpic_paddr + 0x10000); | 90 | mpic_assign_isu(mpic1, 0, res.start + 0x10000); |
92 | 91 | ||
93 | /* 48 Internal Interrupts */ | 92 | /* 48 Internal Interrupts */ |
94 | mpic_assign_isu(mpic1, 1, openpic_paddr + 0x10200); | 93 | mpic_assign_isu(mpic1, 1, res.start + 0x10200); |
95 | mpic_assign_isu(mpic1, 2, openpic_paddr + 0x10400); | 94 | mpic_assign_isu(mpic1, 2, res.start + 0x10400); |
96 | mpic_assign_isu(mpic1, 3, openpic_paddr + 0x10600); | 95 | mpic_assign_isu(mpic1, 3, res.start + 0x10600); |
97 | 96 | ||
98 | /* 16 External interrupts | 97 | /* 16 External interrupts |
99 | * Moving them from [0 - 15] to [64 - 79] | 98 | * Moving them from [0 - 15] to [64 - 79] |
100 | */ | 99 | */ |
101 | mpic_assign_isu(mpic1, 4, openpic_paddr + 0x10000); | 100 | mpic_assign_isu(mpic1, 4, res.start + 0x10000); |
102 | 101 | ||
103 | mpic_init(mpic1); | 102 | mpic_init(mpic1); |
104 | 103 | ||