aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms/83xx/mpc832x_rdb.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc/platforms/83xx/mpc832x_rdb.c')
-rw-r--r--arch/powerpc/platforms/83xx/mpc832x_rdb.c56
1 files changed, 4 insertions, 52 deletions
diff --git a/arch/powerpc/platforms/83xx/mpc832x_rdb.c b/arch/powerpc/platforms/83xx/mpc832x_rdb.c
index 17f99745f0e4..eff5baabc3fb 100644
--- a/arch/powerpc/platforms/83xx/mpc832x_rdb.c
+++ b/arch/powerpc/platforms/83xx/mpc832x_rdb.c
@@ -193,17 +193,14 @@ machine_device_initcall(mpc832x_rdb, mpc832x_spi_init);
193 */ 193 */
194static void __init mpc832x_rdb_setup_arch(void) 194static void __init mpc832x_rdb_setup_arch(void)
195{ 195{
196#if defined(CONFIG_PCI) || defined(CONFIG_QUICC_ENGINE) 196#if defined(CONFIG_QUICC_ENGINE)
197 struct device_node *np; 197 struct device_node *np;
198#endif 198#endif
199 199
200 if (ppc_md.progress) 200 if (ppc_md.progress)
201 ppc_md.progress("mpc832x_rdb_setup_arch()", 0); 201 ppc_md.progress("mpc832x_rdb_setup_arch()", 0);
202 202
203#ifdef CONFIG_PCI 203 mpc83xx_setup_pci();
204 for_each_compatible_node(np, "pci", "fsl,mpc8349-pci")
205 mpc83xx_add_bridge(np);
206#endif
207 204
208#ifdef CONFIG_QUICC_ENGINE 205#ifdef CONFIG_QUICC_ENGINE
209 qe_reset(); 206 qe_reset();
@@ -218,52 +215,7 @@ static void __init mpc832x_rdb_setup_arch(void)
218#endif /* CONFIG_QUICC_ENGINE */ 215#endif /* CONFIG_QUICC_ENGINE */
219} 216}
220 217
221static struct of_device_id mpc832x_ids[] = { 218machine_device_initcall(mpc832x_rdb, mpc83xx_declare_of_platform_devices);
222 { .type = "soc", },
223 { .compatible = "soc", },
224 { .compatible = "simple-bus", },
225 { .type = "qe", },
226 { .compatible = "fsl,qe", },
227 {},
228};
229
230static int __init mpc832x_declare_of_platform_devices(void)
231{
232 /* Publish the QE devices */
233 of_platform_bus_probe(NULL, mpc832x_ids, NULL);
234
235 return 0;
236}
237machine_device_initcall(mpc832x_rdb, mpc832x_declare_of_platform_devices);
238
239static void __init mpc832x_rdb_init_IRQ(void)
240{
241
242 struct device_node *np;
243
244 np = of_find_node_by_type(NULL, "ipic");
245 if (!np)
246 return;
247
248 ipic_init(np, 0);
249
250 /* Initialize the default interrupt mapping priorities,
251 * in case the boot rom changed something on us.
252 */
253 ipic_set_default_priority();
254 of_node_put(np);
255
256#ifdef CONFIG_QUICC_ENGINE
257 np = of_find_compatible_node(NULL, NULL, "fsl,qe-ic");
258 if (!np) {
259 np = of_find_node_by_type(NULL, "qeic");
260 if (!np)
261 return;
262 }
263 qe_ic_init(np, 0, qe_ic_cascade_low_ipic, qe_ic_cascade_high_ipic);
264 of_node_put(np);
265#endif /* CONFIG_QUICC_ENGINE */
266}
267 219
268/* 220/*
269 * Called very early, MMU is off, device-tree isn't unflattened 221 * Called very early, MMU is off, device-tree isn't unflattened
@@ -279,7 +231,7 @@ define_machine(mpc832x_rdb) {
279 .name = "MPC832x RDB", 231 .name = "MPC832x RDB",
280 .probe = mpc832x_rdb_probe, 232 .probe = mpc832x_rdb_probe,
281 .setup_arch = mpc832x_rdb_setup_arch, 233 .setup_arch = mpc832x_rdb_setup_arch,
282 .init_IRQ = mpc832x_rdb_init_IRQ, 234 .init_IRQ = mpc83xx_ipic_and_qe_init_IRQ,
283 .get_irq = ipic_get_irq, 235 .get_irq = ipic_get_irq,
284 .restart = mpc83xx_restart, 236 .restart = mpc83xx_restart,
285 .time_init = mpc83xx_time_init, 237 .time_init = mpc83xx_time_init,