Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

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>

authored by

Masahiro Yamada and committed by
Arnd Bergmann
75305275 635e958d

+64 -64
+1 -1
arch/arm/common/mcpm_platsmp.c
··· 83 83 84 84 #endif 85 85 86 - static struct smp_operations __initdata mcpm_smp_ops = { 86 + static const struct smp_operations mcpm_smp_ops __initconst = { 87 87 .smp_boot_secondary = mcpm_boot_secondary, 88 88 .smp_secondary_init = mcpm_secondary_init, 89 89 #ifdef CONFIG_HOTPLUG_CPU
+1 -1
arch/arm/include/asm/psci.h
··· 14 14 #ifndef __ASM_ARM_PSCI_H 15 15 #define __ASM_ARM_PSCI_H 16 16 17 - extern struct smp_operations psci_smp_ops; 17 + extern const struct smp_operations psci_smp_ops; 18 18 19 19 #ifdef CONFIG_ARM_PSCI 20 20 bool psci_smp_available(void);
+1 -1
arch/arm/kernel/psci_smp.c
··· 120 120 return (psci_ops.cpu_on != NULL); 121 121 } 122 122 123 - struct smp_operations __initdata psci_smp_ops = { 123 + const struct smp_operations psci_smp_ops __initconst = { 124 124 .smp_boot_secondary = psci_boot_secondary, 125 125 #ifdef CONFIG_HOTPLUG_CPU 126 126 .cpu_disable = psci_cpu_disable,
+1 -1
arch/arm/mach-alpine/platsmp.c
··· 42 42 alpine_cpu_pm_init(); 43 43 } 44 44 45 - static struct smp_operations alpine_smp_ops __initdata = { 45 + static const struct smp_operations alpine_smp_ops __initconst = { 46 46 .smp_prepare_cpus = alpine_smp_prepare_cpus, 47 47 .smp_boot_secondary = alpine_boot_secondary, 48 48 };
+1 -1
arch/arm/mach-axxia/platsmp.c
··· 82 82 } 83 83 } 84 84 85 - static struct smp_operations axxia_smp_ops __initdata = { 85 + static const struct smp_operations axxia_smp_ops __initconst = { 86 86 .smp_prepare_cpus = axxia_smp_prepare_cpus, 87 87 .smp_boot_secondary = axxia_boot_secondary, 88 88 };
+1 -1
arch/arm/mach-bcm/bcm63xx_smp.c
··· 161 161 } 162 162 } 163 163 164 - struct smp_operations bcm63138_smp_ops __initdata = { 164 + static const struct smp_operations bcm63138_smp_ops __initconst = { 165 165 .smp_prepare_cpus = bcm63138_smp_prepare_cpus, 166 166 .smp_boot_secondary = bcm63138_smp_boot_secondary, 167 167 };
+1 -1
arch/arm/mach-bcm/kona_smp.c
··· 194 194 return -ENOSYS; 195 195 } 196 196 197 - static struct smp_operations bcm_smp_ops __initdata = { 197 + static const struct smp_operations bcm_smp_ops __initconst = { 198 198 .smp_prepare_cpus = bcm_smp_prepare_cpus, 199 199 .smp_boot_secondary = bcm_boot_secondary, 200 200 };
+1 -1
arch/arm/mach-bcm/platsmp-brcmstb.c
··· 356 356 return 0; 357 357 } 358 358 359 - static struct smp_operations brcmstb_smp_ops __initdata = { 359 + static const struct smp_operations brcmstb_smp_ops __initconst = { 360 360 .smp_prepare_cpus = brcmstb_cpu_ctrl_setup, 361 361 .smp_boot_secondary = brcmstb_boot_secondary, 362 362 #ifdef CONFIG_HOTPLUG_CPU
+1 -1
arch/arm/mach-berlin/platsmp.c
··· 119 119 } 120 120 #endif 121 121 122 - static struct smp_operations berlin_smp_ops __initdata = { 122 + static const struct smp_operations berlin_smp_ops __initconst = { 123 123 .smp_prepare_cpus = berlin_smp_prepare_cpus, 124 124 .smp_boot_secondary = berlin_boot_secondary, 125 125 #ifdef CONFIG_HOTPLUG_CPU
+1 -1
arch/arm/mach-exynos/common.h
··· 149 149 extern void exynos_cpu_resume(void); 150 150 extern void exynos_cpu_resume_ns(void); 151 151 152 - extern struct smp_operations exynos_smp_ops; 152 + extern const struct smp_operations exynos_smp_ops; 153 153 154 154 extern void exynos_cpu_power_down(int cpu); 155 155 extern void exynos_cpu_power_up(int cpu);
+1 -1
arch/arm/mach-exynos/platsmp.c
··· 479 479 } 480 480 #endif /* CONFIG_HOTPLUG_CPU */ 481 481 482 - struct smp_operations exynos_smp_ops __initdata = { 482 + const struct smp_operations exynos_smp_ops __initconst = { 483 483 .smp_init_cpus = exynos_smp_init_cpus, 484 484 .smp_prepare_cpus = exynos_smp_prepare_cpus, 485 485 .smp_secondary_init = exynos_secondary_init,
+1 -1
arch/arm/mach-hisi/platmcpm.c
··· 239 239 } 240 240 #endif 241 241 242 - static struct smp_operations __initdata hip04_smp_ops = { 242 + static const struct smp_operations hip04_smp_ops __initconst = { 243 243 .smp_boot_secondary = hip04_boot_secondary, 244 244 #ifdef CONFIG_HOTPLUG_CPU 245 245 .cpu_die = hip04_cpu_die,
+3 -3
arch/arm/mach-hisi/platsmp.c
··· 89 89 return 0; 90 90 } 91 91 92 - static struct smp_operations hi3xxx_smp_ops __initdata = { 92 + static const struct smp_operations hi3xxx_smp_ops __initconst = { 93 93 .smp_prepare_cpus = hi3xxx_smp_prepare_cpus, 94 94 .smp_boot_secondary = hi3xxx_boot_secondary, 95 95 #ifdef CONFIG_HOTPLUG_CPU ··· 126 126 } 127 127 128 128 129 - static struct smp_operations hix5hd2_smp_ops __initdata = { 129 + static const struct smp_operations hix5hd2_smp_ops __initconst = { 130 130 .smp_prepare_cpus = hisi_common_smp_prepare_cpus, 131 131 .smp_boot_secondary = hix5hd2_boot_secondary, 132 132 #ifdef CONFIG_HOTPLUG_CPU ··· 176 176 return 0; 177 177 } 178 178 179 - static struct smp_operations hip01_smp_ops __initdata = { 179 + static const struct smp_operations hip01_smp_ops __initconst = { 180 180 .smp_prepare_cpus = hisi_common_smp_prepare_cpus, 181 181 .smp_boot_secondary = hip01_boot_secondary, 182 182 };
+2 -2
arch/arm/mach-imx/common.h
··· 153 153 static inline void imx_init_l2cache(void) {} 154 154 #endif 155 155 156 - extern struct smp_operations imx_smp_ops; 157 - extern struct smp_operations ls1021a_smp_ops; 156 + extern const struct smp_operations imx_smp_ops; 157 + extern const struct smp_operations ls1021a_smp_ops; 158 158 159 159 #endif
+2 -2
arch/arm/mach-imx/platsmp.c
··· 88 88 sync_cache_w(&g_diag_reg); 89 89 } 90 90 91 - struct smp_operations imx_smp_ops __initdata = { 91 + const struct smp_operations imx_smp_ops __initconst = { 92 92 .smp_init_cpus = imx_smp_init_cpus, 93 93 .smp_prepare_cpus = imx_smp_prepare_cpus, 94 94 .smp_boot_secondary = imx_boot_secondary, ··· 123 123 iounmap(dcfg_base); 124 124 } 125 125 126 - struct smp_operations ls1021a_smp_ops __initdata = { 126 + const struct smp_operations ls1021a_smp_ops __initconst = { 127 127 .smp_prepare_cpus = ls1021a_smp_prepare_cpus, 128 128 .smp_boot_secondary = ls1021a_boot_secondary, 129 129 };
+1 -1
arch/arm/mach-keystone/keystone.h
··· 15 15 16 16 #ifndef __ASSEMBLER__ 17 17 18 - extern struct smp_operations keystone_smp_ops; 18 + extern const struct smp_operations keystone_smp_ops; 19 19 extern void secondary_startup(void); 20 20 extern u32 keystone_cpu_smc(u32 command, u32 cpu, u32 addr); 21 21 extern int keystone_pm_runtime_init(void);
+1 -1
arch/arm/mach-keystone/platsmp.c
··· 39 39 return error; 40 40 } 41 41 42 - struct smp_operations keystone_smp_ops __initdata = { 42 + const struct smp_operations keystone_smp_ops __initconst = { 43 43 .smp_boot_secondary = keystone_smp_boot_secondary, 44 44 };
+2 -2
arch/arm/mach-mediatek/platsmp.c
··· 128 128 __mtk_smp_prepare_cpus(max_cpus, 0); 129 129 } 130 130 131 - static struct smp_operations mt81xx_tz_smp_ops __initdata = { 131 + static const struct smp_operations mt81xx_tz_smp_ops __initconst = { 132 132 .smp_prepare_cpus = mtk_tz_smp_prepare_cpus, 133 133 .smp_boot_secondary = mtk_boot_secondary, 134 134 }; 135 135 CPU_METHOD_OF_DECLARE(mt81xx_tz_smp, "mediatek,mt81xx-tz-smp", &mt81xx_tz_smp_ops); 136 136 137 - static struct smp_operations mt6589_smp_ops __initdata = { 137 + static const struct smp_operations mt6589_smp_ops __initconst = { 138 138 .smp_prepare_cpus = mtk_smp_prepare_cpus, 139 139 .smp_boot_secondary = mtk_boot_secondary, 140 140 };
+1 -1
arch/arm/mach-mvebu/armada-370-xp.h
··· 17 17 18 18 #ifdef CONFIG_SMP 19 19 void armada_xp_secondary_startup(void); 20 - extern struct smp_operations armada_xp_smp_ops; 20 + extern const struct smp_operations armada_xp_smp_ops; 21 21 #endif 22 22 23 23 #endif /* __MACH_ARMADA_370_XP_H */
+2 -2
arch/arm/mach-mvebu/platsmp-a9.c
··· 93 93 } 94 94 #endif 95 95 96 - static struct smp_operations mvebu_cortex_a9_smp_ops __initdata = { 96 + static const struct smp_operations mvebu_cortex_a9_smp_ops __initconst = { 97 97 .smp_boot_secondary = mvebu_cortex_a9_boot_secondary, 98 98 }; 99 99 100 - static struct smp_operations armada_38x_smp_ops __initdata = { 100 + static const struct smp_operations armada_38x_smp_ops __initconst = { 101 101 .smp_boot_secondary = mvebu_cortex_a9_boot_secondary, 102 102 .smp_secondary_init = armada_38x_secondary_init, 103 103 #ifdef CONFIG_HOTPLUG_CPU
+1 -1
arch/arm/mach-mvebu/platsmp.c
··· 170 170 } 171 171 #endif 172 172 173 - struct smp_operations armada_xp_smp_ops __initdata = { 173 + const struct smp_operations armada_xp_smp_ops __initconst = { 174 174 .smp_init_cpus = armada_xp_smp_init_cpus, 175 175 .smp_prepare_cpus = armada_xp_smp_prepare_cpus, 176 176 .smp_boot_secondary = armada_xp_boot_secondary,
+1 -1
arch/arm/mach-omap2/common.h
··· 270 270 271 271 extern void omap4_cpu_die(unsigned int cpu); 272 272 273 - extern struct smp_operations omap4_smp_ops; 273 + extern const struct smp_operations omap4_smp_ops; 274 274 275 275 extern void omap5_secondary_startup(void); 276 276 extern void omap5_secondary_hyp_startup(void);
+1 -1
arch/arm/mach-omap2/omap-smp.c
··· 241 241 242 242 } 243 243 244 - struct smp_operations omap4_smp_ops __initdata = { 244 + const struct smp_operations omap4_smp_ops __initconst = { 245 245 .smp_init_cpus = omap4_smp_init_cpus, 246 246 .smp_prepare_cpus = omap4_smp_prepare_cpus, 247 247 .smp_secondary_init = omap4_secondary_init,
+1 -1
arch/arm/mach-prima2/common.h
··· 15 15 #include <asm/mach/time.h> 16 16 #include <asm/exception.h> 17 17 18 - extern struct smp_operations sirfsoc_smp_ops; 18 + extern const struct smp_operations sirfsoc_smp_ops; 19 19 extern void sirfsoc_secondary_startup(void); 20 20 extern void sirfsoc_cpu_die(unsigned int cpu); 21 21
+1 -1
arch/arm/mach-prima2/platsmp.c
··· 112 112 return pen_release != -1 ? -ENOSYS : 0; 113 113 } 114 114 115 - struct smp_operations sirfsoc_smp_ops __initdata = { 115 + const struct smp_operations sirfsoc_smp_ops __initconst = { 116 116 .smp_secondary_init = sirfsoc_secondary_init, 117 117 .smp_boot_secondary = sirfsoc_boot_secondary, 118 118 #ifdef CONFIG_HOTPLUG_CPU
+3 -3
arch/arm/mach-qcom/platsmp.c
··· 332 332 } 333 333 } 334 334 335 - static struct smp_operations smp_msm8660_ops __initdata = { 335 + static const struct smp_operations smp_msm8660_ops __initconst = { 336 336 .smp_prepare_cpus = qcom_smp_prepare_cpus, 337 337 .smp_secondary_init = qcom_secondary_init, 338 338 .smp_boot_secondary = msm8660_boot_secondary, ··· 342 342 }; 343 343 CPU_METHOD_OF_DECLARE(qcom_smp, "qcom,gcc-msm8660", &smp_msm8660_ops); 344 344 345 - static struct smp_operations qcom_smp_kpssv1_ops __initdata = { 345 + static const struct smp_operations qcom_smp_kpssv1_ops __initconst = { 346 346 .smp_prepare_cpus = qcom_smp_prepare_cpus, 347 347 .smp_secondary_init = qcom_secondary_init, 348 348 .smp_boot_secondary = kpssv1_boot_secondary, ··· 352 352 }; 353 353 CPU_METHOD_OF_DECLARE(qcom_smp_kpssv1, "qcom,kpss-acc-v1", &qcom_smp_kpssv1_ops); 354 354 355 - static struct smp_operations qcom_smp_kpssv2_ops __initdata = { 355 + static const struct smp_operations qcom_smp_kpssv2_ops __initconst = { 356 356 .smp_prepare_cpus = qcom_smp_prepare_cpus, 357 357 .smp_secondary_init = qcom_secondary_init, 358 358 .smp_boot_secondary = kpssv2_boot_secondary,
+1 -1
arch/arm/mach-realview/core.h
··· 54 54 extern void realview_init_early(void); 55 55 extern void realview_fixup(struct tag *tags, char **from); 56 56 57 - extern struct smp_operations realview_smp_ops; 57 + extern const struct smp_operations realview_smp_ops; 58 58 extern void realview_cpu_die(unsigned int cpu); 59 59 60 60 #endif
+1 -1
arch/arm/mach-realview/platsmp.c
··· 75 75 __io_address(REALVIEW_SYS_FLAGSSET)); 76 76 } 77 77 78 - struct smp_operations realview_smp_ops __initdata = { 78 + const struct smp_operations realview_smp_ops __initconst = { 79 79 .smp_init_cpus = realview_smp_init_cpus, 80 80 .smp_prepare_cpus = realview_smp_prepare_cpus, 81 81 .smp_secondary_init = versatile_secondary_init,
+1 -1
arch/arm/mach-rockchip/platsmp.c
··· 340 340 } 341 341 #endif 342 342 343 - static struct smp_operations rockchip_smp_ops __initdata = { 343 + static const struct smp_operations rockchip_smp_ops __initconst = { 344 344 .smp_prepare_cpus = rockchip_smp_prepare_cpus, 345 345 .smp_boot_secondary = rockchip_boot_secondary, 346 346 #ifdef CONFIG_HOTPLUG_CPU
+1 -1
arch/arm/mach-shmobile/r8a7779.h
··· 3 3 4 4 extern void r8a7779_pm_init(void); 5 5 6 - extern struct smp_operations r8a7779_smp_ops; 6 + extern const struct smp_operations r8a7779_smp_ops; 7 7 8 8 #endif /* __ASM_R8A7779_H__ */
+1 -1
arch/arm/mach-shmobile/r8a7790.h
··· 1 1 #ifndef __ASM_R8A7790_H__ 2 2 #define __ASM_R8A7790_H__ 3 3 4 - extern struct smp_operations r8a7790_smp_ops; 4 + extern const struct smp_operations r8a7790_smp_ops; 5 5 6 6 #endif /* __ASM_R8A7790_H__ */
+1 -1
arch/arm/mach-shmobile/r8a7791.h
··· 1 1 #ifndef __ASM_R8A7791_H__ 2 2 #define __ASM_R8A7791_H__ 3 3 4 - extern struct smp_operations r8a7791_smp_ops; 4 + extern const struct smp_operations r8a7791_smp_ops; 5 5 6 6 #endif /* __ASM_R8A7791_H__ */
+1 -1
arch/arm/mach-shmobile/setup-emev2.c
··· 42 42 NULL, 43 43 }; 44 44 45 - extern struct smp_operations emev2_smp_ops; 45 + extern const struct smp_operations emev2_smp_ops; 46 46 47 47 DT_MACHINE_START(EMEV2_DT, "Generic Emma Mobile EV2 (Flattened Device Tree)") 48 48 .smp = smp_ops(emev2_smp_ops),
+1 -1
arch/arm/mach-shmobile/sh73a0.h
··· 1 1 #ifndef __ASM_SH73A0_H__ 2 2 #define __ASM_SH73A0_H__ 3 3 4 - extern struct smp_operations sh73a0_smp_ops; 4 + extern const struct smp_operations sh73a0_smp_ops; 5 5 6 6 #endif /* __ASM_SH73A0_H__ */
+1 -1
arch/arm/mach-shmobile/smp-emev2.c
··· 49 49 shmobile_smp_scu_prepare_cpus(max_cpus); 50 50 } 51 51 52 - struct smp_operations emev2_smp_ops __initdata = { 52 + const struct smp_operations emev2_smp_ops __initconst = { 53 53 .smp_prepare_cpus = emev2_smp_prepare_cpus, 54 54 .smp_boot_secondary = emev2_boot_secondary, 55 55 };
+1 -1
arch/arm/mach-shmobile/smp-r8a7779.c
··· 117 117 } 118 118 #endif /* CONFIG_HOTPLUG_CPU */ 119 119 120 - struct smp_operations r8a7779_smp_ops __initdata = { 120 + const struct smp_operations r8a7779_smp_ops __initconst = { 121 121 .smp_prepare_cpus = r8a7779_smp_prepare_cpus, 122 122 .smp_boot_secondary = r8a7779_boot_secondary, 123 123 #ifdef CONFIG_HOTPLUG_CPU
+1 -1
arch/arm/mach-shmobile/smp-r8a7790.c
··· 60 60 rcar_sysc_power_up(&r8a7790_ca7_scu); 61 61 } 62 62 63 - struct smp_operations r8a7790_smp_ops __initdata = { 63 + const struct smp_operations r8a7790_smp_ops __initconst = { 64 64 .smp_prepare_cpus = r8a7790_smp_prepare_cpus, 65 65 .smp_boot_secondary = shmobile_smp_apmu_boot_secondary, 66 66 #ifdef CONFIG_HOTPLUG_CPU
+1 -1
arch/arm/mach-shmobile/smp-r8a7791.c
··· 54 54 return shmobile_smp_apmu_boot_secondary(cpu, idle); 55 55 } 56 56 57 - struct smp_operations r8a7791_smp_ops __initdata = { 57 + const struct smp_operations r8a7791_smp_ops __initconst = { 58 58 .smp_prepare_cpus = r8a7791_smp_prepare_cpus, 59 59 .smp_boot_secondary = r8a7791_smp_boot_secondary, 60 60 #ifdef CONFIG_HOTPLUG_CPU
+1 -1
arch/arm/mach-shmobile/smp-sh73a0.c
··· 56 56 shmobile_smp_scu_prepare_cpus(max_cpus); 57 57 } 58 58 59 - struct smp_operations sh73a0_smp_ops __initdata = { 59 + const struct smp_operations sh73a0_smp_ops __initconst = { 60 60 .smp_prepare_cpus = sh73a0_smp_prepare_cpus, 61 61 .smp_boot_secondary = sh73a0_boot_secondary, 62 62 #ifdef CONFIG_HOTPLUG_CPU
+2 -2
arch/arm/mach-socfpga/platsmp.c
··· 117 117 return 1; 118 118 } 119 119 120 - static struct smp_operations socfpga_smp_ops __initdata = { 120 + static const struct smp_operations socfpga_smp_ops __initconst = { 121 121 .smp_prepare_cpus = socfpga_smp_prepare_cpus, 122 122 .smp_boot_secondary = socfpga_boot_secondary, 123 123 #ifdef CONFIG_HOTPLUG_CPU ··· 126 126 #endif 127 127 }; 128 128 129 - static struct smp_operations socfpga_a10_smp_ops __initdata = { 129 + static const struct smp_operations socfpga_a10_smp_ops __initconst = { 130 130 .smp_prepare_cpus = socfpga_smp_prepare_cpus, 131 131 .smp_boot_secondary = socfpga_a10_boot_secondary, 132 132 #ifdef CONFIG_HOTPLUG_CPU
+1 -1
arch/arm/mach-spear/generic.h
··· 39 39 void spear13xx_secondary_startup(void); 40 40 void spear13xx_cpu_die(unsigned int cpu); 41 41 42 - extern struct smp_operations spear13xx_smp_ops; 42 + extern const struct smp_operations spear13xx_smp_ops; 43 43 44 44 #ifdef CONFIG_MACH_SPEAR1310 45 45 void __init spear1310_clk_init(void __iomem *misc_base, void __iomem *ras_base);
+1 -1
arch/arm/mach-spear/platsmp.c
··· 120 120 __raw_writel(virt_to_phys(spear13xx_secondary_startup), SYS_LOCATION); 121 121 } 122 122 123 - struct smp_operations spear13xx_smp_ops __initdata = { 123 + const struct smp_operations spear13xx_smp_ops __initconst = { 124 124 .smp_init_cpus = spear13xx_smp_init_cpus, 125 125 .smp_prepare_cpus = spear13xx_smp_prepare_cpus, 126 126 .smp_secondary_init = spear13xx_secondary_init,
+1 -1
arch/arm/mach-sti/platsmp.c
··· 156 156 } 157 157 } 158 158 159 - struct smp_operations __initdata sti_smp_ops = { 159 + const struct smp_operations sti_smp_ops __initconst = { 160 160 .smp_prepare_cpus = sti_smp_prepare_cpus, 161 161 .smp_secondary_init = sti_secondary_init, 162 162 .smp_boot_secondary = sti_boot_secondary,
+1 -1
arch/arm/mach-sti/smp.h
··· 12 12 #ifndef __MACH_STI_SMP_H 13 13 #define __MACH_STI_SMP_H 14 14 15 - extern struct smp_operations sti_smp_ops; 15 + extern const struct smp_operations sti_smp_ops; 16 16 17 17 void sti_secondary_startup(void); 18 18
+2 -2
arch/arm/mach-sunxi/platsmp.c
··· 116 116 return 0; 117 117 } 118 118 119 - static struct smp_operations sun6i_smp_ops __initdata = { 119 + static const struct smp_operations sun6i_smp_ops __initconst = { 120 120 .smp_prepare_cpus = sun6i_smp_prepare_cpus, 121 121 .smp_boot_secondary = sun6i_smp_boot_secondary, 122 122 }; ··· 185 185 return 0; 186 186 } 187 187 188 - struct smp_operations sun8i_smp_ops __initdata = { 188 + static const struct smp_operations sun8i_smp_ops __initconst = { 189 189 .smp_prepare_cpus = sun8i_smp_prepare_cpus, 190 190 .smp_boot_secondary = sun8i_smp_boot_secondary, 191 191 };
+1 -1
arch/arm/mach-tegra/common.h
··· 1 - extern struct smp_operations tegra_smp_ops; 1 + extern const struct smp_operations tegra_smp_ops; 2 2 3 3 extern int tegra_cpu_kill(unsigned int cpu); 4 4 extern void tegra_cpu_die(unsigned int cpu);
+1 -1
arch/arm/mach-tegra/platsmp.c
··· 192 192 scu_enable(IO_ADDRESS(scu_a9_get_base())); 193 193 } 194 194 195 - struct smp_operations tegra_smp_ops __initdata = { 195 + const struct smp_operations tegra_smp_ops __initconst = { 196 196 .smp_prepare_cpus = tegra_smp_prepare_cpus, 197 197 .smp_secondary_init = tegra_secondary_init, 198 198 .smp_boot_secondary = tegra_boot_secondary,
+1 -1
arch/arm/mach-uniphier/platsmp.c
··· 201 201 return 0; 202 202 } 203 203 204 - static struct smp_operations uniphier_smp_ops __initdata = { 204 + static const struct smp_operations uniphier_smp_ops __initconst = { 205 205 .smp_prepare_cpus = uniphier_smp_prepare_cpus, 206 206 .smp_boot_secondary = uniphier_smp_boot_secondary, 207 207 };
+1 -1
arch/arm/mach-ux500/platsmp.c
··· 98 98 return 0; 99 99 } 100 100 101 - struct smp_operations ux500_smp_ops __initdata = { 101 + static const struct smp_operations ux500_smp_ops __initconst = { 102 102 .smp_prepare_cpus = ux500_smp_prepare_cpus, 103 103 .smp_boot_secondary = ux500_boot_secondary, 104 104 #ifdef CONFIG_HOTPLUG_CPU
+1 -1
arch/arm/mach-vexpress/core.h
··· 1 1 bool vexpress_smp_init_ops(void); 2 2 3 - extern struct smp_operations vexpress_smp_dt_ops; 3 + extern const struct smp_operations vexpress_smp_dt_ops; 4 4 5 5 extern void vexpress_cpu_die(unsigned int cpu);
+1 -1
arch/arm/mach-vexpress/platsmp.c
··· 64 64 vexpress_flags_set(virt_to_phys(versatile_secondary_startup)); 65 65 } 66 66 67 - struct smp_operations __initdata vexpress_smp_dt_ops = { 67 + const struct smp_operations vexpress_smp_dt_ops __initconst = { 68 68 .smp_prepare_cpus = vexpress_smp_dt_prepare_cpus, 69 69 .smp_secondary_init = versatile_secondary_init, 70 70 .smp_boot_secondary = versatile_boot_secondary,
+1 -1
arch/arm/mach-zx/platsmp.c
··· 176 176 scu_power_mode(scu_base, SCU_PM_NORMAL); 177 177 } 178 178 179 - struct smp_operations zx_smp_ops __initdata = { 179 + static const struct smp_operations zx_smp_ops __initconst = { 180 180 .smp_prepare_cpus = zx_smp_prepare_cpus, 181 181 .smp_secondary_init = zx_secondary_init, 182 182 .smp_boot_secondary = zx_boot_secondary,
+1 -1
arch/arm/mach-zynq/common.h
··· 30 30 extern char zynq_secondary_trampoline_jump; 31 31 extern char zynq_secondary_trampoline_end; 32 32 extern int zynq_cpun_start(u32 address, int cpu); 33 - extern struct smp_operations zynq_smp_ops __initdata; 33 + extern const struct smp_operations zynq_smp_ops; 34 34 #endif 35 35 36 36 extern void __iomem *zynq_scu_base;
+1 -1
arch/arm/mach-zynq/platsmp.c
··· 157 157 } 158 158 #endif 159 159 160 - struct smp_operations zynq_smp_ops __initdata = { 160 + const struct smp_operations zynq_smp_ops __initconst = { 161 161 .smp_init_cpus = zynq_smp_init_cpus, 162 162 .smp_prepare_cpus = zynq_smp_prepare_cpus, 163 163 .smp_boot_secondary = zynq_boot_secondary,