aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/mips/bcm47xx/setup.c34
1 files changed, 25 insertions, 9 deletions
diff --git a/arch/mips/bcm47xx/setup.c b/arch/mips/bcm47xx/setup.c
index 2d6e7cccae6b..12d77e9c2cb4 100644
--- a/arch/mips/bcm47xx/setup.c
+++ b/arch/mips/bcm47xx/setup.c
@@ -202,15 +202,6 @@ static void __init bcm47xx_register_bcma(void)
202 panic("Failed to initialize BCMA bus (err %d)", err); 202 panic("Failed to initialize BCMA bus (err %d)", err);
203 203
204 bcm47xx_fill_bcma_boardinfo(&bcm47xx_bus.bcma.bus.boardinfo, NULL); 204 bcm47xx_fill_bcma_boardinfo(&bcm47xx_bus.bcma.bus.boardinfo, NULL);
205
206 /* The BCM4706 has a problem with the CPU wait instruction.
207 * When r4k_wait or r4k_wait_irqoff is used will just hang and
208 * not return from a msleep(). Removing the cpu_wait
209 * functionality is a workaround for this problem. The BCM4716
210 * does not have this problem.
211 */
212 if (bcm47xx_bus.bcma.bus.chipinfo.id == BCMA_CHIP_ID_BCM4706)
213 cpu_wait = NULL;
214} 205}
215#endif 206#endif
216 207
@@ -241,6 +232,31 @@ void __init plat_mem_setup(void)
241 mips_set_machine_name(bcm47xx_board_get_name()); 232 mips_set_machine_name(bcm47xx_board_get_name());
242} 233}
243 234
235static int __init bcm47xx_cpu_fixes(void)
236{
237 switch (bcm47xx_bus_type) {
238#ifdef CONFIG_BCM47XX_SSB
239 case BCM47XX_BUS_TYPE_SSB:
240 /* Nothing to do */
241 break;
242#endif
243#ifdef CONFIG_BCM47XX_BCMA
244 case BCM47XX_BUS_TYPE_BCMA:
245 /* The BCM4706 has a problem with the CPU wait instruction.
246 * When r4k_wait or r4k_wait_irqoff is used will just hang and
247 * not return from a msleep(). Removing the cpu_wait
248 * functionality is a workaround for this problem. The BCM4716
249 * does not have this problem.
250 */
251 if (bcm47xx_bus.bcma.bus.chipinfo.id == BCMA_CHIP_ID_BCM4706)
252 cpu_wait = NULL;
253 break;
254#endif
255 }
256 return 0;
257}
258arch_initcall(bcm47xx_cpu_fixes);
259
244static int __init bcm47xx_register_bus_complete(void) 260static int __init bcm47xx_register_bus_complete(void)
245{ 261{
246 switch (bcm47xx_bus_type) { 262 switch (bcm47xx_bus_type) {