brcm63xx: fix an OOPS when accessing the basemode register on 6368
[openwrt/openwrt.git] / target / linux / brcm63xx / patches-4.4 / 403-6358-enet1-external-mii-clk.patch
index 206fc3f1795f9631d3d18cb3ef11438d60c9c548..334a9342221c0858550bad8d9e50c444d84527d8 100644 (file)
@@ -1,6 +1,6 @@
 --- a/arch/mips/bcm63xx/boards/board_common.c
 +++ b/arch/mips/bcm63xx/boards/board_common.c
-@@ -102,6 +102,8 @@ void __init board_early_setup(const stru
+@@ -99,6 +99,8 @@ void __init board_early_setup(const stru
                if (BCMCPU_IS_6348())
                        val |= GPIO_MODE_6348_G3_EXT_MII |
                                GPIO_MODE_6348_G0_EXT_MII;
@@ -8,7 +8,7 @@
 +                      val |= GPIO_MODE_6358_ENET1_MII_CLK_INV;
        }
  
-       if (BCMCPU_IS_6368() && board.has_enetsw) {
+       bcm_gpio_writel(val, GPIO_MODE_REG);
 --- a/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
 +++ b/arch/mips/include/asm/mach-bcm63xx/bcm63xx_regs.h
 @@ -651,6 +651,8 @@