Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 8058
b: refs/heads/master
c: 1299232
h: refs/heads/master
v: v3
  • Loading branch information
Andrew Morton authored and Linus Torvalds committed Sep 9, 2005
1 parent dfde38c commit ea644bf
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 15 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5dce225bd9ea60e28e17076de63df0dee51b2883
refs/heads/master: 1299232b5743da454c73853b90b3d2d83dce1737
24 changes: 10 additions & 14 deletions trunk/arch/i386/kernel/mpparse.c
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,8 @@ static int MP_valid_apicid(int apicid, int version)

static void __init MP_processor_info (struct mpc_config_processor *m)
{
int ver, apicid, cpu, found_bsp = 0;
physid_mask_t tmp;
int ver, apicid;
physid_mask_t phys_cpu;

if (!(m->mpc_cpuflag & CPU_ENABLED))
return;
Expand Down Expand Up @@ -181,7 +181,6 @@ static void __init MP_processor_info (struct mpc_config_processor *m)
if (m->mpc_cpuflag & CPU_BOOTPROCESSOR) {
Dprintk(" Bootup CPU\n");
boot_cpu_physical_apicid = m->mpc_apicid;
found_bsp = 1;
}

if (num_processors >= NR_CPUS) {
Expand All @@ -195,29 +194,26 @@ static void __init MP_processor_info (struct mpc_config_processor *m)
" Processor ignored.\n", maxcpus);
return;
}
num_processors++;
ver = m->mpc_apicver;

if (!MP_valid_apicid(apicid, ver)) {
printk(KERN_WARNING "Processor #%d INVALID. (Max ID: %d).\n",
m->mpc_apicid, MAX_APICS);
--num_processors;
return;
}

if (found_bsp)
cpu = 0;
else
cpu = num_processors - 1;
cpu_set(cpu, cpu_possible_map);
tmp = apicid_to_cpu_present(apicid);
physids_or(phys_cpu_present_map, phys_cpu_present_map, tmp);

cpu_set(num_processors, cpu_possible_map);
num_processors++;
phys_cpu = apicid_to_cpu_present(apicid);
physids_or(phys_cpu_present_map, phys_cpu_present_map, phys_cpu);

/*
* Validate version
*/
if (ver == 0x0) {
printk(KERN_WARNING "BIOS bug, APIC version is 0 for CPU#%d! fixing up to 0x10. (tell your hw vendor)\n", m->mpc_apicid);
printk(KERN_WARNING "BIOS bug, APIC version is 0 for CPU#%d! "
"fixing up to 0x10. (tell your hw vendor)\n",
m->mpc_apicid);
ver = 0x10;
}
apic_version[m->mpc_apicid] = ver;
Expand Down

0 comments on commit ea644bf

Please sign in to comment.