MIPS: BCM63XX: don't write to the chipid register on reboot
authorMaxime Bizon <mbizon@freebox.fr>
Fri, 13 Jul 2012 07:46:04 +0000 (07:46 +0000)
committerJohn Crispin <blogic@openwrt.org>
Fri, 24 Aug 2012 18:09:00 +0000 (20:09 +0200)
While harmless, it is bad style to do so.

Signed-off-by: Maxime Bizon <mbizon@freebox.fr>
Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
Patchwork: http://patchwork.linux-mips.org/patch/4092/
Signed-off-by: John Crispin <blogic@openwrt.org>
arch/mips/bcm63xx/setup.c

index bd83836..314231b 100644 (file)
@@ -86,6 +86,9 @@ void bcm63xx_machine_reboot(void)
        }
 
        for (i = 0; i < 2; i++) {
+               if (!perf_regs[i])
+                       break;
+
                reg = bcm_perf_readl(perf_regs[i]);
                if (BCMCPU_IS_6348()) {
                        reg &= ~EXTIRQ_CFG_MASK_ALL_6348;