From patchwork Thu Oct 8 15:59:17 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gleb Natapov X-Patchwork-Id: 35479 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id CA823B7B9C for ; Fri, 9 Oct 2009 03:35:32 +1100 (EST) Received: from localhost ([127.0.0.1]:60410 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mvvxh-0002xg-Tw for incoming@patchwork.ozlabs.org; Thu, 08 Oct 2009 12:35:29 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MvvP2-0004qm-7g for qemu-devel@nongnu.org; Thu, 08 Oct 2009 11:59:40 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MvvOv-0004gB-S7 for qemu-devel@nongnu.org; Thu, 08 Oct 2009 11:59:37 -0400 Received: from [199.232.76.173] (port=57567 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MvvOv-0004ei-7Q for qemu-devel@nongnu.org; Thu, 08 Oct 2009 11:59:33 -0400 Received: from mx1.redhat.com ([209.132.183.28]:37794) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MvvOu-0002KM-4P for qemu-devel@nongnu.org; Thu, 08 Oct 2009 11:59:32 -0400 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id n98FxV2M018464; Thu, 8 Oct 2009 11:59:31 -0400 Received: from dhcp-1-237.tlv.redhat.com (dhcp-1-237.tlv.redhat.com [10.35.1.237]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id n98FxTZn026597; Thu, 8 Oct 2009 11:59:30 -0400 Received: by dhcp-1-237.tlv.redhat.com (Postfix, from userid 13519) id EDA2E1336D5; Thu, 8 Oct 2009 17:59:26 +0200 (IST) From: Gleb Natapov To: kevin@koconnor.net Date: Thu, 8 Oct 2009 17:59:17 +0200 Message-Id: <1255017566-26220-13-git-send-email-gleb@redhat.com> In-Reply-To: <1255017566-26220-1-git-send-email-gleb@redhat.com> References: <1255017566-26220-1-git-send-email-gleb@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.12 X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. Cc: qemu-devel@nongnu.org Subject: [Qemu-devel] [PATCH 12/21] Use extended interrupt descriptor for pci irqs. X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org This is necessary to allow freebsd to boot; freebsd chokes if a regular interrupt descriptor specifies an active high pic irq. Qemu pcbios commit aaff1cc0ce8de3c45eec49b9b0e7624576058eda Signed-off-by: Gleb Natapov --- src/acpi-dsdt.dsl | 56 ++++++++++++++++++++++------------------------------ 1 files changed, 24 insertions(+), 32 deletions(-) diff --git a/src/acpi-dsdt.dsl b/src/acpi-dsdt.dsl index 905d58b..b7ac9f6 100644 --- a/src/acpi-dsdt.dsl +++ b/src/acpi-dsdt.dsl @@ -340,7 +340,7 @@ DefinitionBlock ( Name(_HID, EISAID("PNP0C0F")) // PCI interrupt link Name(_UID, 1) Name(_PRS, ResourceTemplate(){ - IRQ (Level, ActiveHigh, Shared) + Interrupt (, Level, ActiveHigh, Shared) { 5, 9, 10, 11 } }) Method (_STA, 0, NotSerialized) @@ -360,14 +360,14 @@ DefinitionBlock ( { Name (PRR0, ResourceTemplate () { - IRQ (Level, ActiveHigh, Shared) + Interrupt (, Level, ActiveHigh, Shared) {1} }) - CreateWordField (PRR0, 0x01, TMP) + CreateDWordField (PRR0, 0x05, TMP) Store (PRQ0, Local0) If (LLess (Local0, 0x80)) { - ShiftLeft (One, Local0, TMP) + Store (Local0, TMP) } Else { @@ -377,17 +377,15 @@ DefinitionBlock ( } Method (_SRS, 1, NotSerialized) { - CreateWordField (Arg0, 0x01, TMP) - FindSetRightBit (TMP, Local0) - Decrement (Local0) - Store (Local0, PRQ0) + CreateDWordField (Arg0, 0x05, TMP) + Store (TMP, PRQ0) } } Device(LNKB){ Name(_HID, EISAID("PNP0C0F")) // PCI interrupt link Name(_UID, 2) Name(_PRS, ResourceTemplate(){ - IRQ (Level, ActiveHigh, Shared) + Interrupt (, Level, ActiveHigh, Shared) { 5, 9, 10, 11 } }) Method (_STA, 0, NotSerialized) @@ -407,14 +405,14 @@ DefinitionBlock ( { Name (PRR0, ResourceTemplate () { - IRQ (Level, ActiveHigh, Shared) + Interrupt (, Level, ActiveHigh, Shared) {1} }) - CreateWordField (PRR0, 0x01, TMP) + CreateDWordField (PRR0, 0x05, TMP) Store (PRQ1, Local0) If (LLess (Local0, 0x80)) { - ShiftLeft (One, Local0, TMP) + Store (Local0, TMP) } Else { @@ -424,17 +422,15 @@ DefinitionBlock ( } Method (_SRS, 1, NotSerialized) { - CreateWordField (Arg0, 0x01, TMP) - FindSetRightBit (TMP, Local0) - Decrement (Local0) - Store (Local0, PRQ1) + CreateDWordField (Arg0, 0x05, TMP) + Store (TMP, PRQ1) } } Device(LNKC){ Name(_HID, EISAID("PNP0C0F")) // PCI interrupt link Name(_UID, 3) Name(_PRS, ResourceTemplate(){ - IRQ (Level, ActiveHigh, Shared) + Interrupt (, Level, ActiveHigh, Shared) { 5, 9, 10, 11 } }) Method (_STA, 0, NotSerialized) @@ -454,14 +450,14 @@ DefinitionBlock ( { Name (PRR0, ResourceTemplate () { - IRQ (Level, ActiveHigh, Shared) + Interrupt (, Level, ActiveHigh, Shared) {1} }) - CreateWordField (PRR0, 0x01, TMP) + CreateDWordField (PRR0, 0x05, TMP) Store (PRQ2, Local0) If (LLess (Local0, 0x80)) { - ShiftLeft (One, Local0, TMP) + Store (Local0, TMP) } Else { @@ -471,17 +467,15 @@ DefinitionBlock ( } Method (_SRS, 1, NotSerialized) { - CreateWordField (Arg0, 0x01, TMP) - FindSetRightBit (TMP, Local0) - Decrement (Local0) - Store (Local0, PRQ2) + CreateDWordField (Arg0, 0x05, TMP) + Store (TMP, PRQ2) } } Device(LNKD){ Name(_HID, EISAID("PNP0C0F")) // PCI interrupt link Name(_UID, 4) Name(_PRS, ResourceTemplate(){ - IRQ (Level, ActiveHigh, Shared) + Interrupt (, Level, ActiveHigh, Shared) { 5, 9, 10, 11 } }) Method (_STA, 0, NotSerialized) @@ -501,14 +495,14 @@ DefinitionBlock ( { Name (PRR0, ResourceTemplate () { - IRQ (Level, ActiveHigh, Shared) + Interrupt (, Level, ActiveHigh, Shared) {1} }) - CreateWordField (PRR0, 0x01, TMP) + CreateDWordField (PRR0, 0x05, TMP) Store (PRQ3, Local0) If (LLess (Local0, 0x80)) { - ShiftLeft (One, Local0, TMP) + Store (Local0, TMP) } Else { @@ -518,10 +512,8 @@ DefinitionBlock ( } Method (_SRS, 1, NotSerialized) { - CreateWordField (Arg0, 0x01, TMP) - FindSetRightBit (TMP, Local0) - Decrement (Local0) - Store (Local0, PRQ3) + CreateDWordField (Arg0, 0x05, TMP) + Store (TMP, PRQ3) } } }