Merge git://git.infradead.org/battery-2.6
[pandora-kernel.git] / arch / mips / oprofile / common.c
index c31e4cf..aa52aa1 100644 (file)
@@ -38,7 +38,7 @@ static int op_mips_create_files(struct super_block * sb, struct dentry * root)
 
        for (i = 0; i < model->num_counters; ++i) {
                struct dentry *dir;
-               char buf[3];
+               char buf[4];
 
                snprintf(buf, sizeof buf, "%d", i);
                dir = oprofilefs_mkdir(sb, root, buf);
@@ -74,7 +74,7 @@ int __init oprofile_arch_init(struct oprofile_operations *ops)
        struct op_mips_model *lmodel = NULL;
        int res;
 
-       switch (current_cpu_data.cputype) {
+       switch (current_cpu_type()) {
        case CPU_5KC:
        case CPU_20KC:
        case CPU_24K:
@@ -83,6 +83,9 @@ int __init oprofile_arch_init(struct oprofile_operations *ops)
        case CPU_74K:
        case CPU_SB1:
        case CPU_SB1A:
+       case CPU_R10000:
+       case CPU_R12000:
+       case CPU_R14000:
                lmodel = &op_model_mipsxx_ops;
                break;