Fix oprofile compilation error.
PATCH 1/1 Fix oprofile compilation error.
Looks like oprofile_arch_init() was changed so that we have to fill in the caller's oprofile_operations instead of setting a pointer to ours.
We can now make the prototype oprofile_operations be __initdata as a copy is being made.
Signed-off-by David Daney <[email protected]>
arch/mips/oprofile/common.c +3 -3
@@ -68,7 +68,7 @@ static void op_mips_stop(void)on_each_cpu (model->cpu_stop,NULL ,0 ,1 ); } -static struct oprofile_operations oprof_mips_ops = { +static struct oprofile_operations oprof_mips_ops__initdata = { .create_files = op_mips_create_files, .setup = op_mips_setup, .start = op_mips_start,
@@ -76,7 +76,7 @@ static struct oprofile_operations oprof_ .cpu_type = NULL }; -int __init oprofile_arch_init (struct oprofile_operations **ops) +int __init oprofile_arch_init (struct oprofile_operations *ops) {struct op_mips_model *lmodel =NULL ;int res;
@@ -101,7 +101,7 @@ int __init oprofile_arch_init(struct opr model = lmodel; oprof_mips_ops.cpu_type = lmodel->cpu_type; - *ops = &oprof_mips_ops; + *ops = oprof_mips_ops;printk (KERN_INFO "oprofile: using %s performance monitoring.\n" , lmodel->cpu_type);