diff --git a/arch/powerpc/perf/imc-pmu.c b/arch/powerpc/perf/imc-pmu.c index 52017f6eafd9151d1bf534e94a7ba335133d636a..a8f95f96d54bb0f3e69ceb4078606d52453eb7cd 100644 --- a/arch/powerpc/perf/imc-pmu.c +++ b/arch/powerpc/perf/imc-pmu.c @@ -1064,7 +1064,7 @@ static int init_nest_pmu_ref(void) */ for_each_possible_cpu(cpu) { nid = cpu_to_node(cpu); - for_each_online_node(i) { + for (i = 0; i < num_possible_nodes(); i++) { if (nest_imc_refc[i].id == nid) { per_cpu(local_nest_imc_refc, cpu) = &nest_imc_refc[i]; break;