From: Mike Travis Date: Thu, 1 Jan 2009 02:08:48 +0000 (-0800) Subject: cpumask: fix compile error when CONFIG_NR_CPUS is not defined X-Git-Tag: v2.6.29-rc1~521^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8fd2d2d5aaf086cfa3b2e2e58cab96b7afdc9e51;p=profile%2Fivi%2Fkernel-adaptation-intel-automotive.git cpumask: fix compile error when CONFIG_NR_CPUS is not defined CONFIG_NR_CPUS will be defined for all arch's whether SMP or not, but it may not have made it into all arches yet. Signed-off-by: Mike Travis Signed-off-by: Ingo Molnar --- diff --git a/drivers/base/cpu.c b/drivers/base/cpu.c index 2aef96f..719ee5c 100644 --- a/drivers/base/cpu.c +++ b/drivers/base/cpu.c @@ -133,7 +133,7 @@ print_cpus_func(present); */ static ssize_t print_cpus_kernel_max(struct sysdev_class *class, char *buf) { - int n = snprintf(buf, PAGE_SIZE-2, "%d\n", CONFIG_NR_CPUS - 1); + int n = snprintf(buf, PAGE_SIZE-2, "%d\n", NR_CPUS - 1); return n; } static SYSDEV_CLASS_ATTR(kernel_max, 0444, print_cpus_kernel_max, NULL);