diff options
Diffstat (limited to 'arch/ia64/sn')
-rw-r--r-- | arch/ia64/sn/kernel/setup.c | 2 | ||||
-rw-r--r-- | arch/ia64/sn/kernel/sn2/sn2_smp.c | 6 | ||||
-rw-r--r-- | arch/ia64/sn/kernel/sn2/sn_hwperf.c | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/arch/ia64/sn/kernel/setup.c b/arch/ia64/sn/kernel/setup.c index 02c5b8a9fb60..12097776afc0 100644 --- a/arch/ia64/sn/kernel/setup.c +++ b/arch/ia64/sn/kernel/setup.c | |||
@@ -750,7 +750,7 @@ nasid_slice_to_cpuid(int nasid, int slice) | |||
750 | { | 750 | { |
751 | long cpu; | 751 | long cpu; |
752 | 752 | ||
753 | for (cpu = 0; cpu < NR_CPUS; cpu++) | 753 | for (cpu = 0; cpu < nr_cpu_ids; cpu++) |
754 | if (cpuid_to_nasid(cpu) == nasid && | 754 | if (cpuid_to_nasid(cpu) == nasid && |
755 | cpuid_to_slice(cpu) == slice) | 755 | cpuid_to_slice(cpu) == slice) |
756 | return cpu; | 756 | return cpu; |
diff --git a/arch/ia64/sn/kernel/sn2/sn2_smp.c b/arch/ia64/sn/kernel/sn2/sn2_smp.c index e585f9a2afb9..209e1eb467da 100644 --- a/arch/ia64/sn/kernel/sn2/sn2_smp.c +++ b/arch/ia64/sn/kernel/sn2/sn2_smp.c | |||
@@ -461,7 +461,7 @@ bool sn_cpu_disable_allowed(int cpu) | |||
461 | 461 | ||
462 | static void *sn2_ptc_seq_start(struct seq_file *file, loff_t * offset) | 462 | static void *sn2_ptc_seq_start(struct seq_file *file, loff_t * offset) |
463 | { | 463 | { |
464 | if (*offset < NR_CPUS) | 464 | if (*offset < nr_cpu_ids) |
465 | return offset; | 465 | return offset; |
466 | return NULL; | 466 | return NULL; |
467 | } | 467 | } |
@@ -469,7 +469,7 @@ static void *sn2_ptc_seq_start(struct seq_file *file, loff_t * offset) | |||
469 | static void *sn2_ptc_seq_next(struct seq_file *file, void *data, loff_t * offset) | 469 | static void *sn2_ptc_seq_next(struct seq_file *file, void *data, loff_t * offset) |
470 | { | 470 | { |
471 | (*offset)++; | 471 | (*offset)++; |
472 | if (*offset < NR_CPUS) | 472 | if (*offset < nr_cpu_ids) |
473 | return offset; | 473 | return offset; |
474 | return NULL; | 474 | return NULL; |
475 | } | 475 | } |
@@ -491,7 +491,7 @@ static int sn2_ptc_seq_show(struct seq_file *file, void *data) | |||
491 | seq_printf(file, "# ptctest %d, flushopt %d\n", sn2_ptctest, sn2_flush_opt); | 491 | seq_printf(file, "# ptctest %d, flushopt %d\n", sn2_ptctest, sn2_flush_opt); |
492 | } | 492 | } |
493 | 493 | ||
494 | if (cpu < NR_CPUS && cpu_online(cpu)) { | 494 | if (cpu < nr_cpu_ids && cpu_online(cpu)) { |
495 | stat = &per_cpu(ptcstats, cpu); | 495 | stat = &per_cpu(ptcstats, cpu); |
496 | seq_printf(file, "cpu %d %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld\n", cpu, stat->ptc_l, | 496 | seq_printf(file, "cpu %d %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld\n", cpu, stat->ptc_l, |
497 | stat->change_rid, stat->shub_ptc_flushes, stat->nodes_flushed, | 497 | stat->change_rid, stat->shub_ptc_flushes, stat->nodes_flushed, |
diff --git a/arch/ia64/sn/kernel/sn2/sn_hwperf.c b/arch/ia64/sn/kernel/sn2/sn_hwperf.c index be339477f906..45f3c2390428 100644 --- a/arch/ia64/sn/kernel/sn2/sn_hwperf.c +++ b/arch/ia64/sn/kernel/sn2/sn_hwperf.c | |||
@@ -612,7 +612,7 @@ static int sn_hwperf_op_cpu(struct sn_hwperf_op_info *op_info) | |||
612 | op_info->a->arg &= SN_HWPERF_ARG_OBJID_MASK; | 612 | op_info->a->arg &= SN_HWPERF_ARG_OBJID_MASK; |
613 | 613 | ||
614 | if (cpu != SN_HWPERF_ARG_ANY_CPU) { | 614 | if (cpu != SN_HWPERF_ARG_ANY_CPU) { |
615 | if (cpu >= NR_CPUS || !cpu_online(cpu)) { | 615 | if (cpu >= nr_cpu_ids || !cpu_online(cpu)) { |
616 | r = -EINVAL; | 616 | r = -EINVAL; |
617 | goto out; | 617 | goto out; |
618 | } | 618 | } |