You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
ARM: use const and __initconst for smp_operations
These smp_operations structures are not over-written, so add "const" qualifier and replace __initdata with __initconst. Also, add "static" where it is possible. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Acked-by: Moritz Fischer <moritz.fischer@ettus.com> Acked-by: Stephen Boyd <sboyd@codeaurora.org> # qcom part Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Patrice Chotard <patrice.chotard@st.com> Acked-by: Heiko Stuebner <heiko@sntech.de> Acked-by: Wei Xu <xuwei5@hisilicon.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Acked-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com> Acked-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Acked-by: Shawn Guo <shawnguo@kernel.org> Acked-by: Matthias Brugger <matthias.bgg@gmail.com> Acked-by: Thierry Reding <treding@nvidia.com> Acked-by: Nicolas Pitre <nico@linaro.org> Acked-by: Liviu Dudau <Liviu.Dudau@arm.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
This commit is contained in:
committed by
Arnd Bergmann
parent
635e958dad
commit
75305275a7
@@ -83,7 +83,7 @@ static void mcpm_cpu_die(unsigned int cpu)
|
||||
|
||||
#endif
|
||||
|
||||
static struct smp_operations __initdata mcpm_smp_ops = {
|
||||
static const struct smp_operations mcpm_smp_ops __initconst = {
|
||||
.smp_boot_secondary = mcpm_boot_secondary,
|
||||
.smp_secondary_init = mcpm_secondary_init,
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
#ifndef __ASM_ARM_PSCI_H
|
||||
#define __ASM_ARM_PSCI_H
|
||||
|
||||
extern struct smp_operations psci_smp_ops;
|
||||
extern const struct smp_operations psci_smp_ops;
|
||||
|
||||
#ifdef CONFIG_ARM_PSCI
|
||||
bool psci_smp_available(void);
|
||||
|
||||
@@ -120,7 +120,7 @@ bool __init psci_smp_available(void)
|
||||
return (psci_ops.cpu_on != NULL);
|
||||
}
|
||||
|
||||
struct smp_operations __initdata psci_smp_ops = {
|
||||
const struct smp_operations psci_smp_ops __initconst = {
|
||||
.smp_boot_secondary = psci_boot_secondary,
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
.cpu_disable = psci_cpu_disable,
|
||||
|
||||
@@ -42,7 +42,7 @@ static void __init alpine_smp_prepare_cpus(unsigned int max_cpus)
|
||||
alpine_cpu_pm_init();
|
||||
}
|
||||
|
||||
static struct smp_operations alpine_smp_ops __initdata = {
|
||||
static const struct smp_operations alpine_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = alpine_smp_prepare_cpus,
|
||||
.smp_boot_secondary = alpine_boot_secondary,
|
||||
};
|
||||
|
||||
@@ -82,7 +82,7 @@ static void __init axxia_smp_prepare_cpus(unsigned int max_cpus)
|
||||
}
|
||||
}
|
||||
|
||||
static struct smp_operations axxia_smp_ops __initdata = {
|
||||
static const struct smp_operations axxia_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = axxia_smp_prepare_cpus,
|
||||
.smp_boot_secondary = axxia_boot_secondary,
|
||||
};
|
||||
|
||||
@@ -161,7 +161,7 @@ static void __init bcm63138_smp_prepare_cpus(unsigned int max_cpus)
|
||||
}
|
||||
}
|
||||
|
||||
struct smp_operations bcm63138_smp_ops __initdata = {
|
||||
static const struct smp_operations bcm63138_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = bcm63138_smp_prepare_cpus,
|
||||
.smp_boot_secondary = bcm63138_smp_boot_secondary,
|
||||
};
|
||||
|
||||
@@ -194,7 +194,7 @@ static int bcm_boot_secondary(unsigned int cpu, struct task_struct *idle)
|
||||
return -ENOSYS;
|
||||
}
|
||||
|
||||
static struct smp_operations bcm_smp_ops __initdata = {
|
||||
static const struct smp_operations bcm_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = bcm_smp_prepare_cpus,
|
||||
.smp_boot_secondary = bcm_boot_secondary,
|
||||
};
|
||||
|
||||
@@ -356,7 +356,7 @@ static int brcmstb_boot_secondary(unsigned int cpu, struct task_struct *idle)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct smp_operations brcmstb_smp_ops __initdata = {
|
||||
static const struct smp_operations brcmstb_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = brcmstb_cpu_ctrl_setup,
|
||||
.smp_boot_secondary = brcmstb_boot_secondary,
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
|
||||
@@ -119,7 +119,7 @@ static int berlin_cpu_kill(unsigned int cpu)
|
||||
}
|
||||
#endif
|
||||
|
||||
static struct smp_operations berlin_smp_ops __initdata = {
|
||||
static const struct smp_operations berlin_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = berlin_smp_prepare_cpus,
|
||||
.smp_boot_secondary = berlin_boot_secondary,
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
|
||||
@@ -149,7 +149,7 @@ static inline void exynos_pm_init(void) {}
|
||||
extern void exynos_cpu_resume(void);
|
||||
extern void exynos_cpu_resume_ns(void);
|
||||
|
||||
extern struct smp_operations exynos_smp_ops;
|
||||
extern const struct smp_operations exynos_smp_ops;
|
||||
|
||||
extern void exynos_cpu_power_down(int cpu);
|
||||
extern void exynos_cpu_power_up(int cpu);
|
||||
|
||||
@@ -479,7 +479,7 @@ static void exynos_cpu_die(unsigned int cpu)
|
||||
}
|
||||
#endif /* CONFIG_HOTPLUG_CPU */
|
||||
|
||||
struct smp_operations exynos_smp_ops __initdata = {
|
||||
const struct smp_operations exynos_smp_ops __initconst = {
|
||||
.smp_init_cpus = exynos_smp_init_cpus,
|
||||
.smp_prepare_cpus = exynos_smp_prepare_cpus,
|
||||
.smp_secondary_init = exynos_secondary_init,
|
||||
|
||||
@@ -239,7 +239,7 @@ err:
|
||||
}
|
||||
#endif
|
||||
|
||||
static struct smp_operations __initdata hip04_smp_ops = {
|
||||
static const struct smp_operations hip04_smp_ops __initconst = {
|
||||
.smp_boot_secondary = hip04_boot_secondary,
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
.cpu_die = hip04_cpu_die,
|
||||
|
||||
@@ -89,7 +89,7 @@ static int hi3xxx_boot_secondary(unsigned int cpu, struct task_struct *idle)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct smp_operations hi3xxx_smp_ops __initdata = {
|
||||
static const struct smp_operations hi3xxx_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = hi3xxx_smp_prepare_cpus,
|
||||
.smp_boot_secondary = hi3xxx_boot_secondary,
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
@@ -126,7 +126,7 @@ static int hix5hd2_boot_secondary(unsigned int cpu, struct task_struct *idle)
|
||||
}
|
||||
|
||||
|
||||
static struct smp_operations hix5hd2_smp_ops __initdata = {
|
||||
static const struct smp_operations hix5hd2_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = hisi_common_smp_prepare_cpus,
|
||||
.smp_boot_secondary = hix5hd2_boot_secondary,
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
@@ -176,7 +176,7 @@ static int hip01_boot_secondary(unsigned int cpu, struct task_struct *idle)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct smp_operations hip01_smp_ops __initdata = {
|
||||
static const struct smp_operations hip01_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = hisi_common_smp_prepare_cpus,
|
||||
.smp_boot_secondary = hip01_boot_secondary,
|
||||
};
|
||||
|
||||
@@ -153,7 +153,7 @@ void imx_init_l2cache(void);
|
||||
static inline void imx_init_l2cache(void) {}
|
||||
#endif
|
||||
|
||||
extern struct smp_operations imx_smp_ops;
|
||||
extern struct smp_operations ls1021a_smp_ops;
|
||||
extern const struct smp_operations imx_smp_ops;
|
||||
extern const struct smp_operations ls1021a_smp_ops;
|
||||
|
||||
#endif
|
||||
|
||||
@@ -88,7 +88,7 @@ static void __init imx_smp_prepare_cpus(unsigned int max_cpus)
|
||||
sync_cache_w(&g_diag_reg);
|
||||
}
|
||||
|
||||
struct smp_operations imx_smp_ops __initdata = {
|
||||
const struct smp_operations imx_smp_ops __initconst = {
|
||||
.smp_init_cpus = imx_smp_init_cpus,
|
||||
.smp_prepare_cpus = imx_smp_prepare_cpus,
|
||||
.smp_boot_secondary = imx_boot_secondary,
|
||||
@@ -123,7 +123,7 @@ static void __init ls1021a_smp_prepare_cpus(unsigned int max_cpus)
|
||||
iounmap(dcfg_base);
|
||||
}
|
||||
|
||||
struct smp_operations ls1021a_smp_ops __initdata = {
|
||||
const struct smp_operations ls1021a_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = ls1021a_smp_prepare_cpus,
|
||||
.smp_boot_secondary = ls1021a_boot_secondary,
|
||||
};
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
#ifndef __ASSEMBLER__
|
||||
|
||||
extern struct smp_operations keystone_smp_ops;
|
||||
extern const struct smp_operations keystone_smp_ops;
|
||||
extern void secondary_startup(void);
|
||||
extern u32 keystone_cpu_smc(u32 command, u32 cpu, u32 addr);
|
||||
extern int keystone_pm_runtime_init(void);
|
||||
|
||||
@@ -39,6 +39,6 @@ static int keystone_smp_boot_secondary(unsigned int cpu,
|
||||
return error;
|
||||
}
|
||||
|
||||
struct smp_operations keystone_smp_ops __initdata = {
|
||||
const struct smp_operations keystone_smp_ops __initconst = {
|
||||
.smp_boot_secondary = keystone_smp_boot_secondary,
|
||||
};
|
||||
|
||||
@@ -128,13 +128,13 @@ static void __init mtk_smp_prepare_cpus(unsigned int max_cpus)
|
||||
__mtk_smp_prepare_cpus(max_cpus, 0);
|
||||
}
|
||||
|
||||
static struct smp_operations mt81xx_tz_smp_ops __initdata = {
|
||||
static const struct smp_operations mt81xx_tz_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = mtk_tz_smp_prepare_cpus,
|
||||
.smp_boot_secondary = mtk_boot_secondary,
|
||||
};
|
||||
CPU_METHOD_OF_DECLARE(mt81xx_tz_smp, "mediatek,mt81xx-tz-smp", &mt81xx_tz_smp_ops);
|
||||
|
||||
static struct smp_operations mt6589_smp_ops __initdata = {
|
||||
static const struct smp_operations mt6589_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = mtk_smp_prepare_cpus,
|
||||
.smp_boot_secondary = mtk_boot_secondary,
|
||||
};
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
|
||||
#ifdef CONFIG_SMP
|
||||
void armada_xp_secondary_startup(void);
|
||||
extern struct smp_operations armada_xp_smp_ops;
|
||||
extern const struct smp_operations armada_xp_smp_ops;
|
||||
#endif
|
||||
|
||||
#endif /* __MACH_ARMADA_370_XP_H */
|
||||
|
||||
@@ -93,11 +93,11 @@ static int armada_38x_cpu_kill(unsigned int cpu)
|
||||
}
|
||||
#endif
|
||||
|
||||
static struct smp_operations mvebu_cortex_a9_smp_ops __initdata = {
|
||||
static const struct smp_operations mvebu_cortex_a9_smp_ops __initconst = {
|
||||
.smp_boot_secondary = mvebu_cortex_a9_boot_secondary,
|
||||
};
|
||||
|
||||
static struct smp_operations armada_38x_smp_ops __initdata = {
|
||||
static const struct smp_operations armada_38x_smp_ops __initconst = {
|
||||
.smp_boot_secondary = mvebu_cortex_a9_boot_secondary,
|
||||
.smp_secondary_init = armada_38x_secondary_init,
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user