diff options
author | Uwe Kleine-König <u.kleine-koenig@pengutronix.de> | 2015-02-18 12:59:45 +0300 |
---|---|---|
committer | Michael Turquette <mturquette@linaro.org> | 2015-04-13 03:18:27 +0300 |
commit | 692d8328e8c039f9497eb862c6cf835de922c061 (patch) | |
tree | bb58cdf8ee1f91581681ce69013e9e280b0fe56f /drivers/clk/hisilicon/clk-hix5hd2.c | |
parent | f6194213cbe871341cd5dfcfe31b4de78ef9503f (diff) | |
download | linux-692d8328e8c039f9497eb862c6cf835de922c061.tar.xz |
clk: don't use __initconst for non-const arrays
The statement
static const char *name[];
defines a modifiable array of pointers to constant chars. That is
*name[0] = 'f';
is forbidden, but
name[0] = "f";
is not. So marking an array that is defined as above with __initconst is
wrong. Either an additional const must be added such that the whole
definition reads:
static const char *const name[] __initconst;
or where this is not possible __initdata must be used.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Michael Turquette <mturquette@linaro.org>
Diffstat (limited to 'drivers/clk/hisilicon/clk-hix5hd2.c')
-rw-r--r-- | drivers/clk/hisilicon/clk-hix5hd2.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/clk/hisilicon/clk-hix5hd2.c b/drivers/clk/hisilicon/clk-hix5hd2.c index 3f369c60fe56..f1d239435826 100644 --- a/drivers/clk/hisilicon/clk-hix5hd2.c +++ b/drivers/clk/hisilicon/clk-hix5hd2.c @@ -46,15 +46,15 @@ static struct hisi_fixed_rate_clock hix5hd2_fixed_rate_clks[] __initdata = { { HIX5HD2_FIXED_83M, "83m", NULL, CLK_IS_ROOT, 83333333, }, }; -static const char *sfc_mux_p[] __initconst = { +static const char *sfc_mux_p[] __initdata = { "24m", "150m", "200m", "100m", "75m", }; static u32 sfc_mux_table[] = {0, 4, 5, 6, 7}; -static const char *sdio_mux_p[] __initconst = { +static const char *sdio_mux_p[] __initdata = { "75m", "100m", "50m", "15m", }; static u32 sdio_mux_table[] = {0, 1, 2, 3}; -static const char *fephy_mux_p[] __initconst = { "25m", "125m"}; +static const char *fephy_mux_p[] __initdata = { "25m", "125m"}; static u32 fephy_mux_table[] = {0, 1}; |