Add #ifdef CONFIG_SUN7I were appropriate to make adding sun4i / sun5i support
later easier.

Signed-off-by: Hans de Goede <[email protected]>
---
 arch/arm/cpu/armv7/sunxi/clock.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm/cpu/armv7/sunxi/clock.c b/arch/arm/cpu/armv7/sunxi/clock.c
index 9cdcc8a..dd01be6 100644
--- a/arch/arm/cpu/armv7/sunxi/clock.c
+++ b/arch/arm/cpu/armv7/sunxi/clock.c
@@ -33,10 +33,12 @@ static void clock_init_safe(void)
               APB0_DIV_1 << APB0_DIV_SHIFT |
               CPU_CLK_SRC_PLL1 << CPU_CLK_SRC_SHIFT,
               &ccm->cpu_ahb_apb0_cfg);
+#ifdef CONFIG_SUN7I
        writel(0x1 << AHB_GATE_OFFSET_DMA | readl(&ccm->ahb_gate0),
               &ccm->ahb_gate0);
        writel(0x1 << PLL6_ENABLE_OFFSET | readl(&ccm->pll6_cfg),
               &ccm->pll6_cfg);
+#endif
 }
 #endif
 
-- 
1.9.0

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to