Commit 4a1caed3 authored by Uwe Kleine-König's avatar Uwe Kleine-König Committed by Stephen Boyd

clk: make several parent names const

Since commit 2893c379 ("clk: make strings in parent name arrays
const") the name of parent clocks can be const. So add more const in
several clock drivers.
Signed-off-by: default avatarUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Acked-by: default avatarHeiko Stuebner <heiko@sntech.de>
Acked-by: default avatarSylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: default avatarStephen Boyd <sboyd@codeaurora.org>
parent 90acb40f
...@@ -38,44 +38,44 @@ ...@@ -38,44 +38,44 @@
#include "clk.h" #include "clk.h"
/* clock parent list */ /* clock parent list */
static const char *timer0_mux_p[] __initdata = { "osc32k", "timerclk01", }; static const char *const timer0_mux_p[] __initconst = { "osc32k", "timerclk01", };
static const char *timer1_mux_p[] __initdata = { "osc32k", "timerclk01", }; static const char *const timer1_mux_p[] __initconst = { "osc32k", "timerclk01", };
static const char *timer2_mux_p[] __initdata = { "osc32k", "timerclk23", }; static const char *const timer2_mux_p[] __initconst = { "osc32k", "timerclk23", };
static const char *timer3_mux_p[] __initdata = { "osc32k", "timerclk23", }; static const char *const timer3_mux_p[] __initconst = { "osc32k", "timerclk23", };
static const char *timer4_mux_p[] __initdata = { "osc32k", "timerclk45", }; static const char *const timer4_mux_p[] __initconst = { "osc32k", "timerclk45", };
static const char *timer5_mux_p[] __initdata = { "osc32k", "timerclk45", }; static const char *const timer5_mux_p[] __initconst = { "osc32k", "timerclk45", };
static const char *timer6_mux_p[] __initdata = { "osc32k", "timerclk67", }; static const char *const timer6_mux_p[] __initconst = { "osc32k", "timerclk67", };
static const char *timer7_mux_p[] __initdata = { "osc32k", "timerclk67", }; static const char *const timer7_mux_p[] __initconst = { "osc32k", "timerclk67", };
static const char *timer8_mux_p[] __initdata = { "osc32k", "timerclk89", }; static const char *const timer8_mux_p[] __initconst = { "osc32k", "timerclk89", };
static const char *timer9_mux_p[] __initdata = { "osc32k", "timerclk89", }; static const char *const timer9_mux_p[] __initconst = { "osc32k", "timerclk89", };
static const char *uart0_mux_p[] __initdata = { "osc26m", "pclk", }; static const char *const uart0_mux_p[] __initconst = { "osc26m", "pclk", };
static const char *uart1_mux_p[] __initdata = { "osc26m", "pclk", }; static const char *const uart1_mux_p[] __initconst = { "osc26m", "pclk", };
static const char *uart2_mux_p[] __initdata = { "osc26m", "pclk", }; static const char *const uart2_mux_p[] __initconst = { "osc26m", "pclk", };
static const char *uart3_mux_p[] __initdata = { "osc26m", "pclk", }; static const char *const uart3_mux_p[] __initconst = { "osc26m", "pclk", };
static const char *uart4_mux_p[] __initdata = { "osc26m", "pclk", }; static const char *const uart4_mux_p[] __initconst = { "osc26m", "pclk", };
static const char *spi0_mux_p[] __initdata = { "osc26m", "rclk_cfgaxi", }; static const char *const spi0_mux_p[] __initconst = { "osc26m", "rclk_cfgaxi", };
static const char *spi1_mux_p[] __initdata = { "osc26m", "rclk_cfgaxi", }; static const char *const spi1_mux_p[] __initconst = { "osc26m", "rclk_cfgaxi", };
static const char *spi2_mux_p[] __initdata = { "osc26m", "rclk_cfgaxi", }; static const char *const spi2_mux_p[] __initconst = { "osc26m", "rclk_cfgaxi", };
/* share axi parent */ /* share axi parent */
static const char *saxi_mux_p[] __initdata = { "armpll3", "armpll2", }; static const char *const saxi_mux_p[] __initconst = { "armpll3", "armpll2", };
static const char *pwm0_mux_p[] __initdata = { "osc32k", "osc26m", }; static const char *const pwm0_mux_p[] __initconst = { "osc32k", "osc26m", };
static const char *pwm1_mux_p[] __initdata = { "osc32k", "osc26m", }; static const char *const pwm1_mux_p[] __initconst = { "osc32k", "osc26m", };
static const char *sd_mux_p[] __initdata = { "armpll2", "armpll3", }; static const char *const sd_mux_p[] __initconst = { "armpll2", "armpll3", };
static const char *mmc1_mux_p[] __initdata = { "armpll2", "armpll3", }; static const char *const mmc1_mux_p[] __initconst = { "armpll2", "armpll3", };
static const char *mmc1_mux2_p[] __initdata = { "osc26m", "mmc1_div", }; static const char *const mmc1_mux2_p[] __initconst = { "osc26m", "mmc1_div", };
static const char *g2d_mux_p[] __initdata = { "armpll2", "armpll3", }; static const char *const g2d_mux_p[] __initconst = { "armpll2", "armpll3", };
static const char *venc_mux_p[] __initdata = { "armpll2", "armpll3", }; static const char *const venc_mux_p[] __initconst = { "armpll2", "armpll3", };
static const char *vdec_mux_p[] __initdata = { "armpll2", "armpll3", }; static const char *const vdec_mux_p[] __initconst = { "armpll2", "armpll3", };
static const char *vpp_mux_p[] __initdata = { "armpll2", "armpll3", }; static const char *const vpp_mux_p[] __initconst = { "armpll2", "armpll3", };
static const char *edc0_mux_p[] __initdata = { "armpll2", "armpll3", }; static const char *const edc0_mux_p[] __initconst = { "armpll2", "armpll3", };
static const char *ldi0_mux_p[] __initdata = { "armpll2", "armpll4", static const char *const ldi0_mux_p[] __initconst = { "armpll2", "armpll4",
"armpll3", "armpll5", }; "armpll3", "armpll5", };
static const char *edc1_mux_p[] __initdata = { "armpll2", "armpll3", }; static const char *const edc1_mux_p[] __initconst = { "armpll2", "armpll3", };
static const char *ldi1_mux_p[] __initdata = { "armpll2", "armpll4", static const char *const ldi1_mux_p[] __initconst = { "armpll2", "armpll4",
"armpll3", "armpll5", }; "armpll3", "armpll5", };
static const char *rclk_hsic_p[] __initdata = { "armpll3", "armpll2", }; static const char *const rclk_hsic_p[] __initconst = { "armpll3", "armpll2", };
static const char *mmc2_mux_p[] __initdata = { "armpll2", "armpll3", }; static const char *const mmc2_mux_p[] __initconst = { "armpll2", "armpll3", };
static const char *mmc3_mux_p[] __initdata = { "armpll2", "armpll3", }; static const char *const mmc3_mux_p[] __initconst = { "armpll2", "armpll3", };
/* fixed rate clocks */ /* fixed rate clocks */
......
...@@ -46,15 +46,15 @@ static struct hisi_fixed_rate_clock hix5hd2_fixed_rate_clks[] __initdata = { ...@@ -46,15 +46,15 @@ static struct hisi_fixed_rate_clock hix5hd2_fixed_rate_clks[] __initdata = {
{ HIX5HD2_FIXED_83M, "83m", NULL, CLK_IS_ROOT, 83333333, }, { HIX5HD2_FIXED_83M, "83m", NULL, CLK_IS_ROOT, 83333333, },
}; };
static const char *sfc_mux_p[] __initdata = { static const char *const sfc_mux_p[] __initconst = {
"24m", "150m", "200m", "100m", "75m", }; "24m", "150m", "200m", "100m", "75m", };
static u32 sfc_mux_table[] = {0, 4, 5, 6, 7}; static u32 sfc_mux_table[] = {0, 4, 5, 6, 7};
static const char *sdio_mux_p[] __initdata = { static const char *const sdio_mux_p[] __initconst = {
"75m", "100m", "50m", "15m", }; "75m", "100m", "50m", "15m", };
static u32 sdio_mux_table[] = {0, 1, 2, 3}; static u32 sdio_mux_table[] = {0, 1, 2, 3};
static const char *fephy_mux_p[] __initdata = { "25m", "125m"}; static const char *const fephy_mux_p[] __initconst = { "25m", "125m"};
static u32 fephy_mux_table[] = {0, 1}; static u32 fephy_mux_table[] = {0, 1};
......
...@@ -55,7 +55,7 @@ struct hisi_fixed_factor_clock { ...@@ -55,7 +55,7 @@ struct hisi_fixed_factor_clock {
struct hisi_mux_clock { struct hisi_mux_clock {
unsigned int id; unsigned int id;
const char *name; const char *name;
const char **parent_names; const char *const *parent_names;
u8 num_parents; u8 num_parents;
unsigned long flags; unsigned long flags;
unsigned long offset; unsigned long offset;
......
...@@ -77,12 +77,12 @@ static void __init clk_misc_init(void) ...@@ -77,12 +77,12 @@ static void __init clk_misc_init(void)
writel_relaxed(30 << BP_FRAC_IOFRAC, FRAC + SET); writel_relaxed(30 << BP_FRAC_IOFRAC, FRAC + SET);
} }
static const char *sel_pll[] __initdata = { "pll", "ref_xtal", }; static const char *const sel_pll[] __initconst = { "pll", "ref_xtal", };
static const char *sel_cpu[] __initdata = { "ref_cpu", "ref_xtal", }; static const char *const sel_cpu[] __initconst = { "ref_cpu", "ref_xtal", };
static const char *sel_pix[] __initdata = { "ref_pix", "ref_xtal", }; static const char *const sel_pix[] __initconst = { "ref_pix", "ref_xtal", };
static const char *sel_io[] __initdata = { "ref_io", "ref_xtal", }; static const char *const sel_io[] __initconst = { "ref_io", "ref_xtal", };
static const char *cpu_sels[] __initdata = { "cpu_pll", "cpu_xtal", }; static const char *const cpu_sels[] __initconst = { "cpu_pll", "cpu_xtal", };
static const char *emi_sels[] __initdata = { "emi_pll", "emi_xtal", }; static const char *const emi_sels[] __initconst = { "emi_pll", "emi_xtal", };
enum imx23_clk { enum imx23_clk {
ref_xtal, pll, ref_cpu, ref_emi, ref_pix, ref_io, saif_sel, ref_xtal, pll, ref_cpu, ref_emi, ref_pix, ref_io, saif_sel,
......
...@@ -125,15 +125,15 @@ static void __init clk_misc_init(void) ...@@ -125,15 +125,15 @@ static void __init clk_misc_init(void)
writel_relaxed(val, FRAC0); writel_relaxed(val, FRAC0);
} }
static const char *sel_cpu[] __initdata = { "ref_cpu", "ref_xtal", }; static const char *const sel_cpu[] __initconst = { "ref_cpu", "ref_xtal", };
static const char *sel_io0[] __initdata = { "ref_io0", "ref_xtal", }; static const char *const sel_io0[] __initconst = { "ref_io0", "ref_xtal", };
static const char *sel_io1[] __initdata = { "ref_io1", "ref_xtal", }; static const char *const sel_io1[] __initconst = { "ref_io1", "ref_xtal", };
static const char *sel_pix[] __initdata = { "ref_pix", "ref_xtal", }; static const char *const sel_pix[] __initconst = { "ref_pix", "ref_xtal", };
static const char *sel_gpmi[] __initdata = { "ref_gpmi", "ref_xtal", }; static const char *const sel_gpmi[] __initconst = { "ref_gpmi", "ref_xtal", };
static const char *sel_pll0[] __initdata = { "pll0", "ref_xtal", }; static const char *const sel_pll0[] __initconst = { "pll0", "ref_xtal", };
static const char *cpu_sels[] __initdata = { "cpu_pll", "cpu_xtal", }; static const char *const cpu_sels[] __initconst = { "cpu_pll", "cpu_xtal", };
static const char *emi_sels[] __initdata = { "emi_pll", "emi_xtal", }; static const char *const emi_sels[] __initconst = { "emi_pll", "emi_xtal", };
static const char *ptp_sels[] __initdata = { "ref_xtal", "pll0", }; static const char *const ptp_sels[] __initconst = { "ref_xtal", "pll0", };
enum imx28_clk { enum imx28_clk {
ref_xtal, pll0, pll1, pll2, ref_cpu, ref_emi, ref_io0, ref_io1, ref_xtal, pll0, pll1, pll2, ref_cpu, ref_emi, ref_io0, ref_io1,
......
...@@ -49,7 +49,7 @@ static inline struct clk *mxs_clk_gate(const char *name, ...@@ -49,7 +49,7 @@ static inline struct clk *mxs_clk_gate(const char *name,
} }
static inline struct clk *mxs_clk_mux(const char *name, void __iomem *reg, static inline struct clk *mxs_clk_mux(const char *name, void __iomem *reg,
u8 shift, u8 width, const char **parent_names, int num_parents) u8 shift, u8 width, const char *const *parent_names, int num_parents)
{ {
return clk_register_mux(NULL, name, parent_names, num_parents, return clk_register_mux(NULL, name, parent_names, num_parents,
CLK_SET_RATE_PARENT | CLK_SET_RATE_NO_REPARENT, CLK_SET_RATE_PARENT | CLK_SET_RATE_NO_REPARENT,
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
#define _CLK_PXA_ #define _CLK_PXA_
#define PARENTS(name) \ #define PARENTS(name) \
static const char *name ## _parents[] __initdata static const char *const name ## _parents[] __initconst
#define MUX_RO_RATE_RO_OPS(name, clk_name) \ #define MUX_RO_RATE_RO_OPS(name, clk_name) \
static struct clk_hw name ## _mux_hw; \ static struct clk_hw name ## _mux_hw; \
static struct clk_hw name ## _rate_hw; \ static struct clk_hw name ## _rate_hw; \
......
...@@ -231,7 +231,7 @@ static int rockchip_cpuclk_notifier_cb(struct notifier_block *nb, ...@@ -231,7 +231,7 @@ static int rockchip_cpuclk_notifier_cb(struct notifier_block *nb,
} }
struct clk *rockchip_clk_register_cpuclk(const char *name, struct clk *rockchip_clk_register_cpuclk(const char *name,
const char **parent_names, u8 num_parents, const char *const *parent_names, u8 num_parents,
const struct rockchip_cpuclk_reg_data *reg_data, const struct rockchip_cpuclk_reg_data *reg_data,
const struct rockchip_cpuclk_rate_table *rates, const struct rockchip_cpuclk_rate_table *rates,
int nrates, void __iomem *reg_base, spinlock_t *lock) int nrates, void __iomem *reg_base, spinlock_t *lock)
......
...@@ -120,7 +120,7 @@ static const struct clk_ops rockchip_mmc_clk_ops = { ...@@ -120,7 +120,7 @@ static const struct clk_ops rockchip_mmc_clk_ops = {
}; };
struct clk *rockchip_clk_register_mmc(const char *name, struct clk *rockchip_clk_register_mmc(const char *name,
const char **parent_names, u8 num_parents, const char *const *parent_names, u8 num_parents,
void __iomem *reg, int shift) void __iomem *reg, int shift)
{ {
struct clk_init_data init; struct clk_init_data init;
......
...@@ -329,10 +329,10 @@ static const struct clk_ops rockchip_rk3066_pll_clk_ops = { ...@@ -329,10 +329,10 @@ static const struct clk_ops rockchip_rk3066_pll_clk_ops = {
*/ */
struct clk *rockchip_clk_register_pll(enum rockchip_pll_type pll_type, struct clk *rockchip_clk_register_pll(enum rockchip_pll_type pll_type,
const char *name, const char **parent_names, u8 num_parents, const char *name, const char *const *parent_names,
void __iomem *base, int con_offset, int grf_lock_offset, u8 num_parents, void __iomem *base, int con_offset,
int lock_shift, int mode_offset, int mode_shift, int grf_lock_offset, int lock_shift, int mode_offset,
struct rockchip_pll_rate_table *rate_table, int mode_shift, struct rockchip_pll_rate_table *rate_table,
u8 clk_pll_flags, spinlock_t *lock) u8 clk_pll_flags, spinlock_t *lock)
{ {
const char *pll_parents[3]; const char *pll_parents[3];
......
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
* sometimes without one of those components. * sometimes without one of those components.
*/ */
static struct clk *rockchip_clk_register_branch(const char *name, static struct clk *rockchip_clk_register_branch(const char *name,
const char **parent_names, u8 num_parents, void __iomem *base, const char *const *parent_names, u8 num_parents, void __iomem *base,
int muxdiv_offset, u8 mux_shift, u8 mux_width, u8 mux_flags, int muxdiv_offset, u8 mux_shift, u8 mux_width, u8 mux_flags,
u8 div_shift, u8 div_width, u8 div_flags, u8 div_shift, u8 div_width, u8 div_flags,
struct clk_div_table *div_table, int gate_offset, struct clk_div_table *div_table, int gate_offset,
...@@ -103,8 +103,8 @@ static struct clk *rockchip_clk_register_branch(const char *name, ...@@ -103,8 +103,8 @@ static struct clk *rockchip_clk_register_branch(const char *name,
} }
static struct clk *rockchip_clk_register_frac_branch(const char *name, static struct clk *rockchip_clk_register_frac_branch(const char *name,
const char **parent_names, u8 num_parents, void __iomem *base, const char *const *parent_names, u8 num_parents,
int muxdiv_offset, u8 div_flags, void __iomem *base, int muxdiv_offset, u8 div_flags,
int gate_offset, u8 gate_shift, u8 gate_flags, int gate_offset, u8 gate_shift, u8 gate_flags,
unsigned long flags, spinlock_t *lock) unsigned long flags, spinlock_t *lock)
{ {
...@@ -297,7 +297,7 @@ void __init rockchip_clk_register_branches( ...@@ -297,7 +297,7 @@ void __init rockchip_clk_register_branches(
} }
void __init rockchip_clk_register_armclk(unsigned int lookup_id, void __init rockchip_clk_register_armclk(unsigned int lookup_id,
const char *name, const char **parent_names, const char *name, const char *const *parent_names,
u8 num_parents, u8 num_parents,
const struct rockchip_cpuclk_reg_data *reg_data, const struct rockchip_cpuclk_reg_data *reg_data,
const struct rockchip_cpuclk_rate_table *rates, const struct rockchip_cpuclk_rate_table *rates,
......
...@@ -108,7 +108,7 @@ struct rockchip_pll_rate_table { ...@@ -108,7 +108,7 @@ struct rockchip_pll_rate_table {
struct rockchip_pll_clock { struct rockchip_pll_clock {
unsigned int id; unsigned int id;
const char *name; const char *name;
const char **parent_names; const char *const *parent_names;
u8 num_parents; u8 num_parents;
unsigned long flags; unsigned long flags;
int con_offset; int con_offset;
...@@ -140,10 +140,10 @@ struct rockchip_pll_clock { ...@@ -140,10 +140,10 @@ struct rockchip_pll_clock {
} }
struct clk *rockchip_clk_register_pll(enum rockchip_pll_type pll_type, struct clk *rockchip_clk_register_pll(enum rockchip_pll_type pll_type,
const char *name, const char **parent_names, u8 num_parents, const char *name, const char *const *parent_names,
void __iomem *base, int con_offset, int grf_lock_offset, u8 num_parents, void __iomem *base, int con_offset,
int lock_shift, int reg_mode, int mode_shift, int grf_lock_offset, int lock_shift, int reg_mode,
struct rockchip_pll_rate_table *rate_table, int mode_shift, struct rockchip_pll_rate_table *rate_table,
u8 clk_pll_flags, spinlock_t *lock); u8 clk_pll_flags, spinlock_t *lock);
struct rockchip_cpuclk_clksel { struct rockchip_cpuclk_clksel {
...@@ -173,16 +173,16 @@ struct rockchip_cpuclk_reg_data { ...@@ -173,16 +173,16 @@ struct rockchip_cpuclk_reg_data {
}; };
struct clk *rockchip_clk_register_cpuclk(const char *name, struct clk *rockchip_clk_register_cpuclk(const char *name,
const char **parent_names, u8 num_parents, const char *const *parent_names, u8 num_parents,
const struct rockchip_cpuclk_reg_data *reg_data, const struct rockchip_cpuclk_reg_data *reg_data,
const struct rockchip_cpuclk_rate_table *rates, const struct rockchip_cpuclk_rate_table *rates,
int nrates, void __iomem *reg_base, spinlock_t *lock); int nrates, void __iomem *reg_base, spinlock_t *lock);
struct clk *rockchip_clk_register_mmc(const char *name, struct clk *rockchip_clk_register_mmc(const char *name,
const char **parent_names, u8 num_parents, const char *const *parent_names, u8 num_parents,
void __iomem *reg, int shift); void __iomem *reg, int shift);
#define PNAME(x) static const char *x[] __initdata #define PNAME(x) static const char *const x[] __initconst
enum rockchip_clk_branch_type { enum rockchip_clk_branch_type {
branch_composite, branch_composite,
...@@ -197,7 +197,7 @@ struct rockchip_clk_branch { ...@@ -197,7 +197,7 @@ struct rockchip_clk_branch {
unsigned int id; unsigned int id;
enum rockchip_clk_branch_type branch_type; enum rockchip_clk_branch_type branch_type;
const char *name; const char *name;
const char **parent_names; const char *const *parent_names;
u8 num_parents; u8 num_parents;
unsigned long flags; unsigned long flags;
int muxdiv_offset; int muxdiv_offset;
...@@ -403,7 +403,7 @@ void rockchip_clk_register_branches(struct rockchip_clk_branch *clk_list, ...@@ -403,7 +403,7 @@ void rockchip_clk_register_branches(struct rockchip_clk_branch *clk_list,
void rockchip_clk_register_plls(struct rockchip_pll_clock *pll_list, void rockchip_clk_register_plls(struct rockchip_pll_clock *pll_list,
unsigned int nr_pll, int grf_lock_offset); unsigned int nr_pll, int grf_lock_offset);
void rockchip_clk_register_armclk(unsigned int lookup_id, const char *name, void rockchip_clk_register_armclk(unsigned int lookup_id, const char *name,
const char **parent_names, u8 num_parents, const char *const *parent_names, u8 num_parents,
const struct rockchip_cpuclk_reg_data *reg_data, const struct rockchip_cpuclk_reg_data *reg_data,
const struct rockchip_cpuclk_rate_table *rates, const struct rockchip_cpuclk_rate_table *rates,
int nrates); int nrates);
......
...@@ -1156,7 +1156,7 @@ static const struct clk_ops samsung_pll2650xx_clk_min_ops = { ...@@ -1156,7 +1156,7 @@ static const struct clk_ops samsung_pll2650xx_clk_min_ops = {
}; };
static void __init _samsung_clk_register_pll(struct samsung_clk_provider *ctx, static void __init _samsung_clk_register_pll(struct samsung_clk_provider *ctx,
struct samsung_pll_clock *pll_clk, const struct samsung_pll_clock *pll_clk,
void __iomem *base) void __iomem *base)
{ {
struct samsung_clk_pll *pll; struct samsung_clk_pll *pll;
...@@ -1303,7 +1303,7 @@ static void __init _samsung_clk_register_pll(struct samsung_clk_provider *ctx, ...@@ -1303,7 +1303,7 @@ static void __init _samsung_clk_register_pll(struct samsung_clk_provider *ctx,
} }
void __init samsung_clk_register_pll(struct samsung_clk_provider *ctx, void __init samsung_clk_register_pll(struct samsung_clk_provider *ctx,
struct samsung_pll_clock *pll_list, const struct samsung_pll_clock *pll_list,
unsigned int nr_pll, void __iomem *base) unsigned int nr_pll, void __iomem *base)
{ {
int cnt; int cnt;
......
This diff is collapsed.
...@@ -98,7 +98,7 @@ void samsung_clk_add_lookup(struct samsung_clk_provider *ctx, struct clk *clk, ...@@ -98,7 +98,7 @@ void samsung_clk_add_lookup(struct samsung_clk_provider *ctx, struct clk *clk,
/* register a list of aliases */ /* register a list of aliases */
void __init samsung_clk_register_alias(struct samsung_clk_provider *ctx, void __init samsung_clk_register_alias(struct samsung_clk_provider *ctx,
struct samsung_clock_alias *list, const struct samsung_clock_alias *list,
unsigned int nr_clk) unsigned int nr_clk)
{ {
struct clk *clk; struct clk *clk;
...@@ -132,7 +132,8 @@ void __init samsung_clk_register_alias(struct samsung_clk_provider *ctx, ...@@ -132,7 +132,8 @@ void __init samsung_clk_register_alias(struct samsung_clk_provider *ctx,
/* register a list of fixed clocks */ /* register a list of fixed clocks */
void __init samsung_clk_register_fixed_rate(struct samsung_clk_provider *ctx, void __init samsung_clk_register_fixed_rate(struct samsung_clk_provider *ctx,
struct samsung_fixed_rate_clock *list, unsigned int nr_clk) const struct samsung_fixed_rate_clock *list,
unsigned int nr_clk)
{ {
struct clk *clk; struct clk *clk;
unsigned int idx, ret; unsigned int idx, ret;
...@@ -161,7 +162,7 @@ void __init samsung_clk_register_fixed_rate(struct samsung_clk_provider *ctx, ...@@ -161,7 +162,7 @@ void __init samsung_clk_register_fixed_rate(struct samsung_clk_provider *ctx,
/* register a list of fixed factor clocks */ /* register a list of fixed factor clocks */
void __init samsung_clk_register_fixed_factor(struct samsung_clk_provider *ctx, void __init samsung_clk_register_fixed_factor(struct samsung_clk_provider *ctx,
struct samsung_fixed_factor_clock *list, unsigned int nr_clk) const struct samsung_fixed_factor_clock *list, unsigned int nr_clk)
{ {
struct clk *clk; struct clk *clk;
unsigned int idx; unsigned int idx;
...@@ -181,7 +182,7 @@ void __init samsung_clk_register_fixed_factor(struct samsung_clk_provider *ctx, ...@@ -181,7 +182,7 @@ void __init samsung_clk_register_fixed_factor(struct samsung_clk_provider *ctx,
/* register a list of mux clocks */ /* register a list of mux clocks */
void __init samsung_clk_register_mux(struct samsung_clk_provider *ctx, void __init samsung_clk_register_mux(struct samsung_clk_provider *ctx,
struct samsung_mux_clock *list, const struct samsung_mux_clock *list,
unsigned int nr_clk) unsigned int nr_clk)
{ {
struct clk *clk; struct clk *clk;
...@@ -213,7 +214,7 @@ void __init samsung_clk_register_mux(struct samsung_clk_provider *ctx, ...@@ -213,7 +214,7 @@ void __init samsung_clk_register_mux(struct samsung_clk_provider *ctx,
/* register a list of div clocks */ /* register a list of div clocks */
void __init samsung_clk_register_div(struct samsung_clk_provider *ctx, void __init samsung_clk_register_div(struct samsung_clk_provider *ctx,
struct samsung_div_clock *list, const struct samsung_div_clock *list,
unsigned int nr_clk) unsigned int nr_clk)
{ {
struct clk *clk; struct clk *clk;
...@@ -252,7 +253,7 @@ void __init samsung_clk_register_div(struct samsung_clk_provider *ctx, ...@@ -252,7 +253,7 @@ void __init samsung_clk_register_div(struct samsung_clk_provider *ctx,
/* register a list of gate clocks */ /* register a list of gate clocks */
void __init samsung_clk_register_gate(struct samsung_clk_provider *ctx, void __init samsung_clk_register_gate(struct samsung_clk_provider *ctx,
struct samsung_gate_clock *list, const struct samsung_gate_clock *list,
unsigned int nr_clk) unsigned int nr_clk)
{ {
struct clk *clk; struct clk *clk;
......
...@@ -121,7 +121,7 @@ struct samsung_mux_clock { ...@@ -121,7 +121,7 @@ struct samsung_mux_clock {
unsigned int id; unsigned int id;
const char *dev_name; const char *dev_name;
const char *name; const char *name;
const char **parent_names; const char *const *parent_names;
u8 num_parents; u8 num_parents;
unsigned long flags; unsigned long flags;
unsigned long offset; unsigned long offset;
...@@ -368,28 +368,28 @@ extern void __init samsung_clk_of_register_fixed_ext( ...@@ -368,28 +368,28 @@ extern void __init samsung_clk_of_register_fixed_ext(
extern void samsung_clk_add_lookup(struct samsung_clk_provider *ctx, extern void samsung_clk_add_lookup(struct samsung_clk_provider *ctx,
struct clk *clk, unsigned int id); struct clk *clk, unsigned int id);
extern void samsung_clk_register_alias(struct samsung_clk_provider *ctx, extern void __init samsung_clk_register_alias(struct samsung_clk_provider *ctx,
struct samsung_clock_alias *list, const struct samsung_clock_alias *list,
unsigned int nr_clk); unsigned int nr_clk);
extern void __init samsung_clk_register_fixed_rate( extern void __init samsung_clk_register_fixed_rate(
struct samsung_clk_provider *ctx, struct samsung_clk_provider *ctx,
struct samsung_fixed_rate_clock *clk_list, const struct samsung_fixed_rate_clock *clk_list,
unsigned int nr_clk); unsigned int nr_clk);
extern void __init samsung_clk_register_fixed_factor( extern void __init samsung_clk_register_fixed_factor(
struct samsung_clk_provider *ctx, struct samsung_clk_provider *ctx,
struct samsung_fixed_factor_clock *list, const struct samsung_fixed_factor_clock *list,
unsigned int nr_clk); unsigned int nr_clk);
extern void __init samsung_clk_register_mux(struct samsung_clk_provider *ctx, extern void __init samsung_clk_register_mux(struct samsung_clk_provider *ctx,
struct samsung_mux_clock *clk_list, const struct samsung_mux_clock *clk_list,
unsigned int nr_clk); unsigned int nr_clk);
extern void __init samsung_clk_register_div(struct samsung_clk_provider *ctx, extern void __init samsung_clk_register_div(struct samsung_clk_provider *ctx,
struct samsung_div_clock *clk_list, const struct samsung_div_clock *clk_list,
unsigned int nr_clk); unsigned int nr_clk);
extern void __init samsung_clk_register_gate(struct samsung_clk_provider *ctx, extern void __init samsung_clk_register_gate(struct samsung_clk_provider *ctx,
struct samsung_gate_clock *clk_list, const struct samsung_gate_clock *clk_list,
unsigned int nr_clk); unsigned int nr_clk);
extern void __init samsung_clk_register_pll(struct samsung_clk_provider *ctx, extern void __init samsung_clk_register_pll(struct samsung_clk_provider *ctx,
struct samsung_pll_clock *pll_list, const struct samsung_pll_clock *pll_list,
unsigned int nr_clk, void __iomem *base); unsigned int nr_clk, void __iomem *base);
extern struct samsung_clk_provider __init *samsung_cmu_register_one( extern struct samsung_clk_provider __init *samsung_cmu_register_one(
......
...@@ -85,22 +85,29 @@ static DEFINE_SPINLOCK(canmioclk_lock); ...@@ -85,22 +85,29 @@ static DEFINE_SPINLOCK(canmioclk_lock);
static DEFINE_SPINLOCK(dbgclk_lock); static DEFINE_SPINLOCK(dbgclk_lock);
static DEFINE_SPINLOCK(aperclk_lock); static DEFINE_SPINLOCK(aperclk_lock);
static const char *armpll_parents[] __initdata = {"armpll_int", "ps_clk"}; static const char *const armpll_parents[] __initconst = {"armpll_int",
static const char *ddrpll_parents[] __initdata = {"ddrpll_int", "ps_clk"}; "ps_clk"};
static const char *iopll_parents[] __initdata = {"iopll_int", "ps_clk"}; static const char *const ddrpll_parents[] __initconst = {"ddrpll_int",
"ps_clk"};
static const char *const iopll_parents[] __initconst = {"iopll_int",
"ps_clk"};
static const char *gem0_mux_parents[] __initdata = {"gem0_div1", "dummy_name"}; static const char *gem0_mux_parents[] __initdata = {"gem0_div1", "dummy_name"};
static const char *gem1_mux_parents[] __initdata = {"gem1_div1", "dummy_name"}; static const char *gem1_mux_parents[] __initdata = {"gem1_div1", "dummy_name"};
static const char *can0_mio_mux2_parents[] __initdata = {"can0_gate", static const char *const can0_mio_mux2_parents[] __initconst = {"can0_gate",
"can0_mio_mux"}; "can0_mio_mux"};
static const char *can1_mio_mux2_parents[] __initdata = {"can1_gate", static const char *const can1_mio_mux2_parents[] __initconst = {"can1_gate",
"can1_mio_mux"}; "can1_mio_mux"};
static const char *dbg_emio_mux_parents[] __initdata = {"dbg_div", static const char *dbg_emio_mux_parents[] __initdata = {"dbg_div",
"dummy_name"}; "dummy_name"};
static const char *dbgtrc_emio_input_names[] __initdata = {"trace_emio_clk"}; static const char *const dbgtrc_emio_input_names[] __initconst = {
static const char *gem0_emio_input_names[] __initdata = {"gem0_emio_clk"}; "trace_emio_clk"};
static const char *gem1_emio_input_names[] __initdata = {"gem1_emio_clk"}; static const char *const gem0_emio_input_names[] __initconst = {
static const char *swdt_ext_clk_input_names[] __initdata = {"swdt_ext_clk"}; "gem0_emio_clk"};
static const char *const gem1_emio_input_names[] __initconst = {
"gem1_emio_clk"};
static const char *const swdt_ext_clk_input_names[] __initconst = {
"swdt_ext_clk"};
static void __init zynq_clk_register_fclk(enum zynq_clk fclk, static void __init zynq_clk_register_fclk(enum zynq_clk fclk,
const char *clk_name, void __iomem *fclk_ctrl_reg, const char *clk_name, void __iomem *fclk_ctrl_reg,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment