Commit b8c0e7d7c4e9fe3ec00757053a33605eda1c5ac4

Authored by Anthony Liguori
1 parent d8d2e079

Fix non-ACPI Timer Interrupt Routing - v3

v1 -> v2 adds comment suggested by Ryan.
v2 -> v3 clarifies comment and corrects entry count

Signed-off-by: Beth Kon <eak@us.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
pc-bios/bios-pq/0013_fix-non-acpi-timer-interrupt-routing.patch
1 -Fix non-ACPI Timer Interrupt Routing (Beth Kon) 1 +From c09142004a409bf27070939f470c5e0b37595a5a Mon Sep 17 00:00:00 2001
  2 +From: Beth Kon <eak@us.ibm.com>
  3 +Date: Fri, 19 Jun 2009 14:22:00 -0400
  4 +Subject: [PATCH] Fix non-ACPI Timer Interrupt Routing - v3
2 5
3 Replicate ACPI irq0->inti2 override in mp table for non-acpi case. 6 Replicate ACPI irq0->inti2 override in mp table for non-acpi case.
4 7
5 v1 -> v2 adds comment suggested by Ryan. 8 v1 -> v2 adds comment suggested by Ryan.
  9 +v2 -> v3 clarifies comment and corrects entry count
6 10
7 Signed-off-by: Beth Kon <eak@us.ibm.com> 11 Signed-off-by: Beth Kon <eak@us.ibm.com>
8 Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> 12 Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
  13 +---
  14 + bios/rombios32.c | 14 ++++++++++++++
  15 + 1 files changed, 14 insertions(+), 0 deletions(-)
9 16
10 diff --git a/bios/rombios32.c b/bios/rombios32.c 17 diff --git a/bios/rombios32.c b/bios/rombios32.c
11 -index 7be4216..dc7b5f3 100644 18 +index 1a1ed64..d789e20 100644
12 --- a/bios/rombios32.c 19 --- a/bios/rombios32.c
13 +++ b/bios/rombios32.c 20 +++ b/bios/rombios32.c
14 -@@ -1168,6 +1168,12 @@ static void mptable_init(void) 21 +@@ -1124,7 +1124,11 @@ static void mptable_init(void)
  22 + putstr(&q, "0.1 "); /* vendor id */
  23 + putle32(&q, 0); /* OEM table ptr */
  24 + putle16(&q, 0); /* OEM table size */
  25 ++#ifdef BX_QEMU
  26 ++ putle16(&q, smp_cpus + 17); /* entry count */
  27 ++#else
  28 + putle16(&q, smp_cpus + 18); /* entry count */
  29 ++#endif
  30 + putle32(&q, 0xfee00000); /* local APIC addr */
  31 + putle16(&q, 0); /* ext table length */
  32 + putb(&q, 0); /* ext table checksum */
  33 +@@ -1166,6 +1170,12 @@ static void mptable_init(void)
15 34
16 /* irqs */ 35 /* irqs */
17 for(i = 0; i < 16; i++) { 36 for(i = 0; i < 16; i++) {
18 +#ifdef BX_QEMU 37 +#ifdef BX_QEMU
19 -+ /* One entry per ioapic input. Input 2 is covered by  
20 -+ irq0->inti2 override (i == 0). irq 2 is unused */ 38 ++ /* One entry per ioapic interrupt destination. Destination 2 is covered
  39 ++ by irq0->inti2 override (i == 0). Source IRQ 2 is unused */
21 + if (i == 2) 40 + if (i == 2)
22 + continue; 41 + continue;
23 -+#endif 42 ++#endif
24 putb(&q, 3); /* entry type = I/O interrupt */ 43 putb(&q, 3); /* entry type = I/O interrupt */
25 putb(&q, 0); /* interrupt type = vectored interrupt */ 44 putb(&q, 0); /* interrupt type = vectored interrupt */
26 putb(&q, 0); /* flags: po=0, el=0 */ 45 putb(&q, 0); /* flags: po=0, el=0 */
27 -@@ -1175,7 +1181,11 @@ static void mptable_init(void) 46 +@@ -1173,7 +1183,11 @@ static void mptable_init(void)
28 putb(&q, 0); /* source bus ID = ISA */ 47 putb(&q, 0); /* source bus ID = ISA */
29 putb(&q, i); /* source bus IRQ */ 48 putb(&q, i); /* source bus IRQ */
30 putb(&q, ioapic_id); /* dest I/O APIC ID */ 49 putb(&q, ioapic_id); /* dest I/O APIC ID */
@@ -32,7 +51,10 @@ index 7be4216..dc7b5f3 100644 @@ -32,7 +51,10 @@ index 7be4216..dc7b5f3 100644
32 + putb(&q, i == 0 ? 2 : i); /* dest I/O APIC interrupt in */ 51 + putb(&q, i == 0 ? 2 : i); /* dest I/O APIC interrupt in */
33 +#else 52 +#else
34 putb(&q, i); /* dest I/O APIC interrupt in */ 53 putb(&q, i); /* dest I/O APIC interrupt in */
35 -+#endif 54 ++#endif
36 } 55 }
37 /* patch length */ 56 /* patch length */
38 len = q - mp_config_table; 57 len = q - mp_config_table;
  58 +--
  59 +1.6.2.5
  60 +
pc-bios/bios.bin
No preview for this file type