x86_64: Get rid of cpu_apic_versions
authorSepherosa Ziehau <sephe@dragonflybsd.org>
Thu, 5 May 2011 08:29:54 +0000 (16:29 +0800)
committerSepherosa Ziehau <sephe@dragonflybsd.org>
Thu, 5 May 2011 08:29:54 +0000 (16:29 +0800)
sys/platform/pc64/include/smp.h
sys/platform/pc64/x86_64/mp_machdep.c

index 0c94eab..317ccc0 100644 (file)
@@ -70,7 +70,6 @@ extern void (*cpustop_restartfunc) (void);
 extern int                     imcr_present;
 extern int                     apic_io_enable;
 extern int                     mp_naps;
-extern u_int32_t               cpu_apic_versions[];
 extern int                     cpu_num_to_apic_id[];
 extern int                     apic_id_to_logical[];
 
index 4d352c8..33ea052 100644 (file)
@@ -138,7 +138,6 @@ extern struct region_descriptor r_gdt, r_idt;
 int    mp_naps;                /* # of Applications processors */
 extern int nkpt;
 
-u_int32_t cpu_apic_versions[NAPICID];  /* populated during mptable scan */
 int64_t tsc0_offset;
 extern int64_t tsc_offsets[];
 
@@ -229,12 +228,9 @@ mp_announce(void)
        POSTCODE(MP_ANNOUNCE_POST);
 
        kprintf("DragonFly/MP: Multiprocessor motherboard\n");
-       kprintf(" cpu0 (BSP): apic id: %2d", CPU_TO_ID(0));
-       kprintf(", version: 0x%08x\n", cpu_apic_versions[0]);
-       for (x = 1; x <= mp_naps; ++x) {
-               kprintf(" cpu%d (AP):  apic id: %2d", x, CPU_TO_ID(x));
-               kprintf(", version: 0x%08x\n", cpu_apic_versions[x]);
-       }
+       kprintf(" cpu0 (BSP): apic id: %2d\n", CPU_TO_ID(0));
+       for (x = 1; x <= mp_naps; ++x)
+               kprintf(" cpu%d (AP):  apic id: %2d\n", x, CPU_TO_ID(x));
 
        if (!apic_io_enable)
                kprintf(" Warning: APIC I/O disabled\n");
@@ -340,9 +336,6 @@ init_secondary(void)
 
        /* disable the APIC, just to be SURE */
        lapic->svr &= ~APIC_SVR_ENABLE;
-
-       /* data returned to BSP */
-       cpu_apic_versions[0] = lapic->version;
 }
 
 /*******************************************************************
@@ -520,9 +513,6 @@ start_all_aps(u_int boot_addr)
                                panic("bye-bye");
                }
                CHECK_PRINT("trace");           /* show checkpoints */
-
-               /* record its version info */
-               cpu_apic_versions[x] = cpu_apic_versions[0];
        }
 
        /* set ncpus to 1 + highest logical cpu.  Not all may have come up */
@@ -547,9 +537,6 @@ start_all_aps(u_int boot_addr)
        mycpu->gd_ipiq = (void *)kmem_alloc(&kernel_map, sizeof(lwkt_ipiq) * ncpus);
        bzero(mycpu->gd_ipiq, sizeof(lwkt_ipiq) * ncpus);
 
-       /* fill in our (BSP) APIC version */
-       cpu_apic_versions[0] = lapic->version;
-
        /* restore the warmstart vector */
        *(u_long *) WARMBOOT_OFF = mpbioswarmvec;
        outb(CMOS_REG, BIOS_RESET);