Explorar o código

NR_CPUS: Replace NR_CPUS in arch/x86/kernel/genapic_flat_64.c

  * nr_cpu_ids should be used to determine if a percpu area is
    available for a given cpu.

Signed-off-by: Mike Travis <travis@sgi.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Mike Travis %!s(int64=17) %!d(string=hai) anos
pai
achega
1bd9d6b64e
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      arch/x86/kernel/genapic_flat_64.c

+ 1 - 1
arch/x86/kernel/genapic_flat_64.c

@@ -168,7 +168,7 @@ static unsigned int physflat_cpu_mask_to_apicid(cpumask_t cpumask)
 	 * May as well be the first.
 	 */
 	cpu = first_cpu(cpumask);
-	if ((unsigned)cpu < NR_CPUS)
+	if ((unsigned)cpu < nr_cpu_ids)
 		return per_cpu(x86_cpu_to_apicid, cpu);
 	else
 		return BAD_APICID;