public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* use smp_cpus as lapic id
@ 2008-03-03 16:26 Glauber Costa
  2008-03-04  8:40 ` Avi Kivity
  0 siblings, 1 reply; 2+ messages in thread
From: Glauber Costa @ 2008-03-03 16:26 UTC (permalink / raw)
  To: Avi Kivity, kvm-devel, Marcelo Tosatti

[-- Attachment #1: Type: text/plain, Size: 373 bytes --]

apic is not acpi, although they are acronyms. Due to a confusion of 
mine, those things were mixed, leading to a bug reported at
https://sourceforge.net/tracker/index.php?func=detail&aid=1903732&group_id=180599&atid=893831

This patch fixes it, by assigning smp_cpus instead of MAX_CPUS to 
lapic_id in the MP APIC tables.

Signed-off-by: Glauber Costa <gcosta@redhat.com>

[-- Attachment #2: apic_id.patch --]
[-- Type: text/x-patch, Size: 875 bytes --]

diff --git a/bios/rombios32.c b/bios/rombios32.c
index 77e71ac..af18390 100755
--- a/bios/rombios32.c
+++ b/bios/rombios32.c
@@ -983,7 +983,7 @@ #endif
     putstr(&q, "ISA   ");
 
     /* ioapic */
-    ioapic_id = MAX_CPUS;
+    ioapic_id = smp_cpus;
     putb(&q, 2); /* entry type = I/O APIC */
     putb(&q, ioapic_id); /* apic ID */
     putb(&q, 0x11); /* I/O APIC version number */
@@ -1427,7 +1427,7 @@ #endif
         io_apic = (void *)apic;
         io_apic->type = APIC_IO;
         io_apic->length = sizeof(*io_apic);
-        io_apic->io_apic_id = MAX_CPUS;
+        io_apic->io_apic_id = smp_cpus;
         io_apic->address = cpu_to_le32(0xfec00000);
         io_apic->interrupt = cpu_to_le32(0);
 
diff --git a/qemu/pc-bios/bios.bin b/qemu/pc-bios/bios.bin
index 64b7abb..3a75ff5 100644
Binary files a/qemu/pc-bios/bios.bin and b/qemu/pc-bios/bios.bin differ

[-- Attachment #3: Type: text/plain, Size: 228 bytes --]

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

[-- Attachment #4: Type: text/plain, Size: 158 bytes --]

_______________________________________________
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: use smp_cpus as lapic id
  2008-03-03 16:26 use smp_cpus as lapic id Glauber Costa
@ 2008-03-04  8:40 ` Avi Kivity
  0 siblings, 0 replies; 2+ messages in thread
From: Avi Kivity @ 2008-03-04  8:40 UTC (permalink / raw)
  To: Glauber Costa; +Cc: kvm-devel, Marcelo Tosatti

Glauber Costa wrote:
> apic is not acpi, although they are acronyms. Due to a confusion of 
> mine, those things were mixed, leading to a bug reported at
> https://sourceforge.net/tracker/index.php?func=detail&aid=1903732&group_id=180599&atid=893831 
>
>
> This patch fixes it, by assigning smp_cpus instead of MAX_CPUS to 
> lapic_id in the MP APIC tables.
>

Applied, thanks.

-- 
error compiling committee.c: too many arguments to function


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-03-04  8:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-03-03 16:26 use smp_cpus as lapic id Glauber Costa
2008-03-04  8:40 ` Avi Kivity

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox