Skip to contentSkip to conversation

fix siblings field value in /proc/cpuinfo

PATCH New Siddha, Suresh B 1 participant 1 message Oct 4, 2005

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 fix siblings field value in /proc/cpuinfo

Tony, Please apply the appended patch.

thanks,
suresh

--
Fix the "siblings" field value in /proc/cpuinfo so that it now shows the number of siblings as seen by OS, instead of what is available from hardware perspective.

arch/ia64/kernel/setup.c +1 -1
diff -pNru linux-2.6.14-rc3/arch/ia64/kernel/setup.c linux-2.6.14-rc3-core/arch/ia64/kernel/setup.c
@@ -526,7 +526,7 @@ show_cpuinfo (struct seq_file *m, void *
 		   c->itc_freq / 1000000, c->itc_freq % 1000000,
 		   lpj*HZ/500000, (lpj*HZ/5000) % 100);
 #ifdef CONFIG_SMP
-	seq_printf(m, "siblings   : %u\n", c->num_log);
+	seq_printf(m, "siblings   : %u\n", cpus_weight(cpu_core_map[cpunum]));
 	if (c->threads_per_core > 1 || c->cores_per_socket > 1)
 		seq_printf(m,
 		   	   "physical id: %u\n"