aboutsummaryrefslogtreecommitdiffstats
path: root/arch/ia64/kernel/setup.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/ia64/kernel/setup.c')
-rw-r--r--arch/ia64/kernel/setup.c49
1 files changed, 8 insertions, 41 deletions
diff --git a/arch/ia64/kernel/setup.c b/arch/ia64/kernel/setup.c
index ae6c3c02e117..2b3751eef5ce 100644
--- a/arch/ia64/kernel/setup.c
+++ b/arch/ia64/kernel/setup.c
@@ -417,34 +417,6 @@ mark_bsp_online (void)
417#endif 417#endif
418} 418}
419 419
420#ifdef CONFIG_SMP
421static void __init
422check_for_logical_procs (void)
423{
424 pal_logical_to_physical_t info;
425 s64 status;
426
427 status = ia64_pal_logical_to_phys(0, &info);
428 if (status == -1) {
429 printk(KERN_INFO "No logical to physical processor mapping "
430 "available\n");
431 return;
432 }
433 if (status) {
434 printk(KERN_ERR "ia64_pal_logical_to_phys failed with %ld\n",
435 status);
436 return;
437 }
438 /*
439 * Total number of siblings that BSP has. Though not all of them
440 * may have booted successfully. The correct number of siblings
441 * booted is in info.overview_num_log.
442 */
443 smp_num_siblings = info.overview_tpc;
444 smp_num_cpucores = info.overview_cpp;
445}
446#endif
447
448static __initdata int nomca; 420static __initdata int nomca;
449static __init int setup_nomca(char *s) 421static __init int setup_nomca(char *s)
450{ 422{
@@ -540,15 +512,6 @@ setup_arch (char **cmdline_p)
540 512
541#ifdef CONFIG_SMP 513#ifdef CONFIG_SMP
542 cpu_physical_id(0) = hard_smp_processor_id(); 514 cpu_physical_id(0) = hard_smp_processor_id();
543 check_for_logical_procs();
544 if (smp_num_cpucores > 1)
545 printk(KERN_INFO
546 "cpu package is Multi-Core capable: number of cores=%d\n",
547 smp_num_cpucores);
548 if (smp_num_siblings > 1)
549 printk(KERN_INFO
550 "cpu package is Multi-Threading capable: number of siblings=%d\n",
551 smp_num_siblings);
552#endif 515#endif
553 516
554 cpu_init(); /* initialize the bootstrap CPU */ 517 cpu_init(); /* initialize the bootstrap CPU */
@@ -661,12 +624,13 @@ show_cpuinfo (struct seq_file *m, void *v)
661 lpj*HZ/500000, (lpj*HZ/5000) % 100); 624 lpj*HZ/500000, (lpj*HZ/5000) % 100);
662#ifdef CONFIG_SMP 625#ifdef CONFIG_SMP
663 seq_printf(m, "siblings : %u\n", cpus_weight(cpu_core_map[cpunum])); 626 seq_printf(m, "siblings : %u\n", cpus_weight(cpu_core_map[cpunum]));
627 if (c->socket_id != -1)
628 seq_printf(m, "physical id: %u\n", c->socket_id);
664 if (c->threads_per_core > 1 || c->cores_per_socket > 1) 629 if (c->threads_per_core > 1 || c->cores_per_socket > 1)
665 seq_printf(m, 630 seq_printf(m,
666 "physical id: %u\n" 631 "core id : %u\n"
667 "core id : %u\n" 632 "thread id : %u\n",
668 "thread id : %u\n", 633 c->core_id, c->thread_id);
669 c->socket_id, c->core_id, c->thread_id);
670#endif 634#endif
671 seq_printf(m,"\n"); 635 seq_printf(m,"\n");
672 636
@@ -778,6 +742,9 @@ identify_cpu (struct cpuinfo_ia64 *c)
778 c->socket_id = -1; 742 c->socket_id = -1;
779 743
780 identify_siblings(c); 744 identify_siblings(c);
745
746 if (c->threads_per_core > smp_num_siblings)
747 smp_num_siblings = c->threads_per_core;
781#endif 748#endif
782 c->ppn = cpuid.field.ppn; 749 c->ppn = cpuid.field.ppn;
783 c->number = cpuid.field.number; 750 c->number = cpuid.field.number;