26 #include <linux/rtc.h>
28 #include <asm/machdep.h>
37 #include <linux/pci.h>
40 { .compatible =
"ibm,plb4", },
41 { .compatible =
"ibm,plb6", },
42 { .compatible =
"ibm,opb", },
43 { .compatible =
"ibm,ebc", },
52 pci_write_config_dword(dev, 0xe0, 0x0114231f);
53 pci_write_config_dword(dev, 0xe4, 0x00006c40);
58 static int __init ppc47x_device_probe(
void)
60 of_platform_bus_probe(
NULL, ppc47x_of_bus,
NULL);
67 static void __init ppc47x_init_irq(
void)
72 for_each_node_with_property(np,
"interrupt-controller") {
77 panic(
"Can't find top level interrupt controller");
85 mpic_alloc(np, 0, MPIC_NO_RESET, 0, 0,
" MPIC ");
90 panic(
"Unrecognized top level interrupt controller");
102 const u64 *spin_table_addr_prop;
104 extern void start_secondary_47x(
void);
112 spin_table_addr_prop =
115 if (spin_table_addr_prop ==
NULL) {
116 pr_err(
"CPU%d: Can't start, missing cpu-release-addr !\n",
126 spin_table = (
u32 *)
__va(*spin_table_addr_prop);
127 pr_debug(
"CPU%d: Spin table mapped at %p\n", cpu, spin_table);
131 spin_table[1] =
__pa(start_secondary_47x);
137 static struct smp_ops_t ppc47x_smp_ops = {
138 .probe = smp_mpic_probe,
139 .message_pass = smp_mpic_message_pass,
140 .setup_cpu = smp_ppc47x_setup_cpu,
141 .kick_cpu = smp_ppc47x_kick_cpu,
146 static void __init ppc47x_smp_init(
void)
148 if (mmu_has_feature(MMU_FTR_TYPE_47x))
153 static void __init ppc47x_smp_init(
void) { }
156 static void __init ppc47x_setup_arch(
void)
169 static int __init ppc47x_probe(
void)
171 unsigned long root = of_get_flat_dt_root();
173 if (!of_flat_dt_is_compatible(root,
"ibm,currituck"))
180 static void ppc47x_pci_irq_fixup(
struct pci_dev *dev)
185 pr_info(
"%s: Mapping irq 47 %d\n", __func__, dev->
irq);
190 .name =
"PowerPC 47x",
191 .probe = ppc47x_probe,
193 .init_IRQ = ppc47x_init_irq,
194 .setup_arch = ppc47x_setup_arch,
195 .pci_irq_fixup = ppc47x_pci_irq_fixup,