x86: reduce memory and intra-node effects

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Этот коммит содержится в:
Mike Travis
2008-01-30 13:33:14 +01:00
коммит произвёл Ingo Molnar
родитель 4dbf7af644
Коммит 693e3c5603
5 изменённых файлов: 14 добавлений и 9 удалений

Просмотреть файл

@@ -1175,14 +1175,15 @@ __cpuinit int apic_is_clustered_box(void)
{
int i, clusters, zeros;
unsigned id;
u16 *bios_cpu_apicid = x86_bios_cpu_apicid_early_ptr;
DECLARE_BITMAP(clustermap, NUM_APIC_CLUSTERS);
bitmap_zero(clustermap, NUM_APIC_CLUSTERS);
for (i = 0; i < NR_CPUS; i++) {
/* are we being called early in kernel startup? */
if (x86_bios_cpu_apicid_early_ptr) {
id = ((u16 *)x86_bios_cpu_apicid_early_ptr)[i];
if (bios_cpu_apicid) {
id = bios_cpu_apicid[i];
}
else if (i < nr_cpu_ids) {
if (cpu_present(i))

Просмотреть файл

@@ -122,7 +122,7 @@ static void __cpuinit MP_processor_info(struct mpc_config_processor *m)
physid_set(m->mpc_apicid, phys_cpu_present_map);
if (m->mpc_cpuflag & CPU_BOOTPROCESSOR) {
/*
* x86_bios_cpu_apicid is required to have processors listed
* x86_bios_cpu_apicid is required to have processors listed
* in same order as logical cpu numbers. Hence the first
* entry is BSP, and so on.
*/
@@ -130,8 +130,8 @@ static void __cpuinit MP_processor_info(struct mpc_config_processor *m)
}
/* are we being called early in kernel startup? */
if (x86_cpu_to_apicid_early_ptr) {
u16 *cpu_to_apicid = (u16 *)x86_cpu_to_apicid_early_ptr;
u16 *bios_cpu_apicid = (u16 *)x86_bios_cpu_apicid_early_ptr;
u16 *cpu_to_apicid = x86_cpu_to_apicid_early_ptr;
u16 *bios_cpu_apicid = x86_bios_cpu_apicid_early_ptr;
cpu_to_apicid[cpu] = m->mpc_apicid;
bios_cpu_apicid[cpu] = m->mpc_apicid;