diff options
author | bz <bz@FreeBSD.org> | 2009-01-31 21:40:27 +0000 |
---|---|---|
committer | bz <bz@FreeBSD.org> | 2009-01-31 21:40:27 +0000 |
commit | 6d6ef97dba70f689eb7e7dd1a77b2c8cad3e8c00 (patch) | |
tree | 8b06459915d4086ccff75c40c0cc93bbe0442c61 /sys/i386 | |
parent | 3d748c01033e762d4936d16234c604e8337e0003 (diff) | |
download | FreeBSD-src-6d6ef97dba70f689eb7e7dd1a77b2c8cad3e8c00.zip FreeBSD-src-6d6ef97dba70f689eb7e7dd1a77b2c8cad3e8c00.tar.gz |
Bring over the code from sys/i386/i386/mp_machdep.c, r187880
to make XEN config compile again:
- Allocate apic vectors on a per-cpu basis.
Diffstat (limited to 'sys/i386')
-rw-r--r-- | sys/i386/xen/mp_machdep.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/i386/xen/mp_machdep.c b/sys/i386/xen/mp_machdep.c index 874cde8..3389b79 100644 --- a/sys/i386/xen/mp_machdep.c +++ b/sys/i386/xen/mp_machdep.c @@ -137,6 +137,7 @@ struct cpu_info { int cpu_disabled:1; } static cpu_info[MAX_APIC_ID + 1]; int cpu_apic_ids[MAXCPU]; +int apic_cpuids[MAX_APIC_ID + 1]; /* Holds pending bitmap based IPIs per CPU */ static volatile u_int cpu_ipi_pending[MAXCPU]; @@ -284,6 +285,7 @@ cpu_mp_start(void) KASSERT(boot_cpu_id == PCPU_GET(apic_id), ("BSP's APIC ID doesn't match boot_cpu_id")); cpu_apic_ids[0] = boot_cpu_id; + apic_cpuids[boot_cpu_id] = 0; assign_cpu_ids(); @@ -707,6 +709,7 @@ assign_cpu_ids(void) if (mp_ncpus < MAXCPU) { cpu_apic_ids[mp_ncpus] = i; + apic_cpuids[i] = mp_ncpus; mp_ncpus++; } else cpu_info[i].cpu_disabled = 1; |