
From: Ashok Raj <ashok.raj@intel.com>

Need to create sysfs only for cpus that are present.  Without which we see
NR_CPUS entries created when we have CONFIG_HOTPLUG and CONFIG_HOTPLUG_CPU
enabled.

Signed-off-by: Ashok Raj <ashok.raj@intel.com>
Cc: Andi Kleen <ak@muc.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
---

 arch/i386/mach-default/topology.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff -puN arch/i386/mach-default/topology.c~x86_64-create-sysfs-entries-for-cpu-only-for-present-cpus arch/i386/mach-default/topology.c
--- devel/arch/i386/mach-default/topology.c~x86_64-create-sysfs-entries-for-cpu-only-for-present-cpus	2005-08-01 17:11:59.000000000 -0700
+++ devel-akpm/arch/i386/mach-default/topology.c	2005-08-01 17:11:59.000000000 -0700
@@ -76,7 +76,7 @@ static int __init topology_init(void)
 	for_each_online_node(i)
 		arch_register_node(i);
 
-	for_each_cpu(i)
+	for_each_present_cpu(i)
 		arch_register_cpu(i);
 	return 0;
 }
@@ -87,7 +87,7 @@ static int __init topology_init(void)
 {
 	int i;
 
-	for_each_cpu(i)
+	for_each_present_cpu(i)
 		arch_register_cpu(i);
 	return 0;
 }
_
