#endif /* CONFIG_HOTPLUG_CPU */
 
-struct plat_smp_ops octeon_smp_ops = {
+const struct plat_smp_ops octeon_smp_ops = {
        .send_ipi_single        = octeon_send_ipi_single,
        .send_ipi_mask          = octeon_send_ipi_mask,
        .init_secondary         = octeon_init_secondary,
                octeon_78xx_send_ipi_single(cpu, action);
 }
 
-static struct plat_smp_ops octeon_78xx_smp_ops = {
+static const struct plat_smp_ops octeon_78xx_smp_ops = {
        .send_ipi_single        = octeon_78xx_send_ipi_single,
        .send_ipi_mask          = octeon_78xx_send_ipi_mask,
        .init_secondary         = octeon_init_secondary,
 
 void __init octeon_setup_smp(void)
 {
-       struct plat_smp_ops *ops;
+       const struct plat_smp_ops *ops;
 
        if (octeon_has_feature(OCTEON_FEATURE_CIU3))
                ops = &octeon_78xx_smp_ops;
 
 #endif
 #ifdef CONFIG_SGI_IP27
        {
-               extern struct plat_smp_ops ip27_smp_ops;
+               extern const struct plat_smp_ops ip27_smp_ops;
 
                register_smp_ops(&ip27_smp_ops);
        }
 
 #include <asm/r4kcache.h>
 #include <asm/smp-ops.h>
 
-extern struct plat_smp_ops bmips43xx_smp_ops;
-extern struct plat_smp_ops bmips5000_smp_ops;
+extern const struct plat_smp_ops bmips43xx_smp_ops;
+extern const struct plat_smp_ops bmips5000_smp_ops;
 
 static inline int register_bmips_smp_ops(void)
 {
 
 /* environment arguments from bootloader */
 extern u32 cpu_clock_freq;
 extern u32 memsize, highmemsize;
-extern struct plat_smp_ops loongson3_smp_ops;
+extern const struct plat_smp_ops loongson3_smp_ops;
 
 /* loongson-specific command line, env and memory initialization */
 extern void __init prom_init_memory(void);
 
  */
 void nlm_init_boot_cpu(void);
 unsigned int nlm_get_cpu_frequency(void);
-extern struct plat_smp_ops nlm_smp_ops;
+extern const struct plat_smp_ops nlm_smp_ops;
 extern char nlm_reset_entry[], nlm_reset_entry_end[];
 
 /* SWIOTLB */
 
 #endif
 };
 
-extern void register_smp_ops(struct plat_smp_ops *ops);
+extern void register_smp_ops(const struct plat_smp_ops *ops);
 
 static inline void plat_smp_setup(void)
 {
-       extern struct plat_smp_ops *mp_ops;     /* private */
+       extern const struct plat_smp_ops *mp_ops;       /* private */
 
        mp_ops->smp_setup();
 }
        /* UP, nothing to do ...  */
 }
 
-static inline void register_smp_ops(struct plat_smp_ops *ops)
+static inline void register_smp_ops(const struct plat_smp_ops *ops)
 {
 }
 
 static inline int register_up_smp_ops(void)
 {
 #ifdef CONFIG_SMP_UP
-       extern struct plat_smp_ops up_smp_ops;
+       extern const struct plat_smp_ops up_smp_ops;
 
        register_smp_ops(&up_smp_ops);
 
 static inline int register_cmp_smp_ops(void)
 {
 #ifdef CONFIG_MIPS_CMP
-       extern struct plat_smp_ops cmp_smp_ops;
+       extern const struct plat_smp_ops cmp_smp_ops;
 
        if (!mips_cm_present())
                return -ENODEV;
 static inline int register_vsmp_smp_ops(void)
 {
 #ifdef CONFIG_MIPS_MT_SMP
-       extern struct plat_smp_ops vsmp_smp_ops;
+       extern const struct plat_smp_ops vsmp_smp_ops;
 
        register_smp_ops(&vsmp_smp_ops);
 
 
  */
 static inline void smp_send_reschedule(int cpu)
 {
-       extern struct plat_smp_ops *mp_ops;     /* private */
+       extern const struct plat_smp_ops *mp_ops;       /* private */
 
        mp_ops->send_ipi_single(cpu, SMP_RESCHEDULE_YOURSELF);
 }
 #ifdef CONFIG_HOTPLUG_CPU
 static inline int __cpu_disable(void)
 {
-       extern struct plat_smp_ops *mp_ops;     /* private */
+       extern const struct plat_smp_ops *mp_ops;       /* private */
 
        return mp_ops->cpu_disable();
 }
 
 static inline void __cpu_die(unsigned int cpu)
 {
-       extern struct plat_smp_ops *mp_ops;     /* private */
+       extern const struct plat_smp_ops *mp_ops;       /* private */
 
        mp_ops->cpu_die(cpu);
 }
 
 static inline void arch_send_call_function_single_ipi(int cpu)
 {
-       extern struct plat_smp_ops *mp_ops;     /* private */
+       extern const struct plat_smp_ops *mp_ops;       /* private */
 
        mp_ops->send_ipi_mask(cpumask_of(cpu), SMP_CALL_FUNCTION);
 }
 
 static inline void arch_send_call_function_ipi_mask(const struct cpumask *mask)
 {
-       extern struct plat_smp_ops *mp_ops;     /* private */
+       extern const struct plat_smp_ops *mp_ops;       /* private */
 
        mp_ops->send_ipi_mask(mask, SMP_CALL_FUNCTION);
 }
 
 
 #endif /* CONFIG_HOTPLUG_CPU */
 
-struct plat_smp_ops bmips43xx_smp_ops = {
+const struct plat_smp_ops bmips43xx_smp_ops = {
        .smp_setup              = bmips_smp_setup,
        .prepare_cpus           = bmips_prepare_cpus,
        .boot_secondary         = bmips_boot_secondary,
 #endif
 };
 
-struct plat_smp_ops bmips5000_smp_ops = {
+const struct plat_smp_ops bmips5000_smp_ops = {
        .smp_setup              = bmips_smp_setup,
        .prepare_cpus           = bmips_prepare_cpus,
        .boot_secondary         = bmips_boot_secondary,
 
 
 }
 
-struct plat_smp_ops cmp_smp_ops = {
+const struct plat_smp_ops cmp_smp_ops = {
        .send_ipi_single        = mips_smp_send_ipi_single,
        .send_ipi_mask          = mips_smp_send_ipi_mask,
        .init_secondary         = cmp_init_secondary,
 
 
 #endif /* CONFIG_HOTPLUG_CPU */
 
-static struct plat_smp_ops cps_smp_ops = {
+static const struct plat_smp_ops cps_smp_ops = {
        .smp_setup              = cps_smp_setup,
        .prepare_cpus           = cps_prepare_cpus,
        .boot_secondary         = cps_boot_secondary,
 
 bool mips_cps_smp_in_use(void)
 {
-       extern struct plat_smp_ops *mp_ops;
+       extern const struct plat_smp_ops *mp_ops;
        return mp_ops == &cps_smp_ops;
 }
 
 
        mips_mt_set_cpuoptions();
 }
 
-struct plat_smp_ops vsmp_smp_ops = {
+const struct plat_smp_ops vsmp_smp_ops = {
        .send_ipi_single        = mips_smp_send_ipi_single,
        .send_ipi_mask          = mips_smp_send_ipi_mask,
        .init_secondary         = vsmp_init_secondary,
 
 }
 #endif
 
-struct plat_smp_ops up_smp_ops = {
+const struct plat_smp_ops up_smp_ops = {
        .send_ipi_single        = up_send_ipi_single,
        .send_ipi_mask          = up_send_ipi_mask,
        .init_secondary         = up_init_secondary,
 
                               &temp_foreign_map, &cpu_sibling_map[i]);
 }
 
-struct plat_smp_ops *mp_ops;
+const struct plat_smp_ops *mp_ops;
 EXPORT_SYMBOL(mp_ops);
 
-void register_smp_ops(struct plat_smp_ops *ops)
+void register_smp_ops(const struct plat_smp_ops *ops)
 {
        if (mp_ops)
                printk(KERN_WARNING "Overriding previously set SMP ops\n");
 
 
 #endif
 
-struct plat_smp_ops loongson3_smp_ops = {
+const struct plat_smp_ops loongson3_smp_ops = {
        .send_ipi_single = loongson3_send_ipi_single,
        .send_ipi_mask = loongson3_send_ipi_mask,
        .init_secondary = loongson3_init_secondary,
 
        return 0;
 }
 
-struct plat_smp_ops nlm_smp_ops = {
+const struct plat_smp_ops nlm_smp_ops = {
        .send_ipi_single        = nlm_send_ipi_single,
        .send_ipi_mask          = nlm_send_ipi_mask,
        .init_secondary         = nlm_init_secondary,
 
        }
 }
 
-struct plat_smp_ops paravirt_smp_ops = {
+const struct plat_smp_ops paravirt_smp_ops = {
        .send_ipi_single        = paravirt_send_ipi_single,
        .send_ipi_mask          = paravirt_send_ipi_mask,
        .init_secondary         = paravirt_init_secondary,
 
 #include <asm/smp-ops.h>
 #include <asm/time.h>
 
-extern struct plat_smp_ops paravirt_smp_ops;
+extern const struct plat_smp_ops paravirt_smp_ops;
 
 const char *get_system_type(void)
 {
 
        /* We already did everything necessary earlier */
 }
 
-struct plat_smp_ops ip27_smp_ops = {
+const struct plat_smp_ops ip27_smp_ops = {
        .send_ipi_single        = ip27_send_ipi_single,
        .send_ipi_mask          = ip27_send_ipi_mask,
        .init_secondary         = ip27_init_secondary,
 
 {
 }
 
-struct plat_smp_ops bcm1480_smp_ops = {
+const struct plat_smp_ops bcm1480_smp_ops = {
        .send_ipi_single        = bcm1480_send_ipi_single,
        .send_ipi_mask          = bcm1480_send_ipi_mask,
        .init_secondary         = bcm1480_init_secondary,
 
 
 #endif
 
-extern struct plat_smp_ops sb_smp_ops;
-extern struct plat_smp_ops bcm1480_smp_ops;
+extern const struct plat_smp_ops sb_smp_ops;
+extern const struct plat_smp_ops bcm1480_smp_ops;
 
 /*
  * prom_init is called just after the cpu type is determined, from setup_arch()
 
 {
 }
 
-struct plat_smp_ops sb_smp_ops = {
+const struct plat_smp_ops sb_smp_ops = {
        .send_ipi_single        = sb1250_send_ipi_single,
        .send_ipi_mask          = sb1250_send_ipi_mask,
        .init_secondary         = sb1250_init_secondary,