summaryrefslogtreecommitdiff
path: root/arch/arm/mach-uniphier/debug-uart/debug-uart-pro5.c
diff options
context:
space:
mode:
authorMasahiro Yamada <yamada.masahiro@socionext.com>2019-07-10 20:07:41 +0900
committerMasahiro Yamada <yamada.masahiro@socionext.com>2019-07-10 22:42:02 +0900
commit739ba41d5a0964a9bc0d5705055ddb706d7e070d (patch)
tree8102586f592acf93236ca9acd4336a8c82a1e0b4 /arch/arm/mach-uniphier/debug-uart/debug-uart-pro5.c
parentd41b358fb331c2907f1f217686d38eeaf17eece4 (diff)
ARM: uniphier: de-couple SC macros into base address and offset
The SC_* macros represent the address of SysCtrl registers. For a planned new SoC, its base address will be changed. Turn the SC_* macros into the offset from the base address. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'arch/arm/mach-uniphier/debug-uart/debug-uart-pro5.c')
-rw-r--r--arch/arm/mach-uniphier/debug-uart/debug-uart-pro5.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm/mach-uniphier/debug-uart/debug-uart-pro5.c b/arch/arm/mach-uniphier/debug-uart/debug-uart-pro5.c
index 8e4d15c2913..ef3b383ee43 100644
--- a/arch/arm/mach-uniphier/debug-uart/debug-uart-pro5.c
+++ b/arch/arm/mach-uniphier/debug-uart/debug-uart-pro5.c
@@ -25,9 +25,9 @@ unsigned int uniphier_pro5_debug_uart_init(void)
writel(1, sg_base + SG_LOADPINCTRL);
- tmp = readl(SC_CLKCTRL);
+ tmp = readl(sc_base + SC_CLKCTRL);
tmp |= SC_CLKCTRL_CEN_PERI;
- writel(tmp, SC_CLKCTRL);
+ writel(tmp, sc_base + SC_CLKCTRL);
return DIV_ROUND_CLOSEST(UNIPHIER_PRO5_UART_CLK, 16 * CONFIG_BAUDRATE);
}