Skip to contentSkip to conversation

clk: hisilicon: mark wdt_mux_p[] as const

PATCH Applied Arnd Bergmann 2 participants 2 messages Feb 20, 2018 – Mar 16, 2018 Common clk

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 clk: hisilicon: mark wdt_mux_p[] as const

The symbol is in the __initconst section but not marked init, which caused a warning when building with LTO.

This makes it 'const' as was obviously intended.

---
 drivers/clk/hisilicon/crg-hi3516cv300.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/clk/hisilicon/crg-hi3516cv300.c +1 -1
index 2007123832bb..53450b651e4c 100644
@@ -204,7 +204,7 @@ static const struct hisi_crg_funcs hi3516cv300_crg_funcs = {
 /* hi3516CV300 sysctrl CRG */
 #define HI3516CV300_SYSCTRL_NR_CLKS 16
 
-static const char *wdt_mux_p[] __initconst = { "3m", "apb" };
+static const char *const wdt_mux_p[] __initconst = { "3m", "apb" };
 static u32 wdt_mux_table[] = {0, 1};
 
 static const struct hisi_mux_clock hi3516cv300_sysctrl_mux_clks[] = {
Signature · 1 line
2.9.0
maintainer Applied
#1 lore raw

Quoting Arnd Bergmann (2018-02-20 07:15:21)

Quoted 9 lines

The symbol is in the __initconst section but not marked init, which caused a warning when building with LTO.
=

This makes it 'const' as was obviously intended.
=

---

Applied to clk-next