WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

RE: [Xen-devel] pvops-2.6.32 - Interrupt routing problem

To: Bastian Blank <waldi@xxxxxxxxxx>
Subject: RE: [Xen-devel] pvops-2.6.32 - Interrupt routing problem
From: "Zhang, Xiantao" <xiantao.zhang@xxxxxxxxx>
Date: Mon, 15 Mar 2010 21:48:15 +0800
Accept-language: en-US
Acceptlanguage: en-US
Cc: Jeremy Fitzhardinge <jeremy@xxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>, Fraser <keir.fraser@xxxxxxxxxxxxx>, "Keir@xxxxxxxxxxxxxxxxxxxxxxx" <Keir@xxxxxxxxxxxxxxxxxxxxxxx>
Delivery-date: Mon, 15 Mar 2010 06:48:50 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <20100315101126.GA24650@xxxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <20100310111923.GA7087@xxxxxxxxxxxxxxxxxxxxxxx> <20100314140813.GA5309@xxxxxxxxxxxxxxxxxxxxxxx> <20100314152334.GA6483@xxxxxxxxxxxxxxxxxxxxxxx> <4B9D0726.3060304@xxxxxxxx> <20100314161750.GA7790@xxxxxxxxxxxxxxxxxxxxxxx> <EB8593BCECAB3D40A8248BE0B6400A38464169F7@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx> <20100315101126.GA24650@xxxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcrEKCbrCcjCbvrDSRy7HCrGhElLVwAHOVgw
Thread-topic: [Xen-devel] pvops-2.6.32 - Interrupt routing problem
With my previous patch, seems you still need to apply the following patch to 
xen.git. In this way, the GSI 0-15 are still setup by hypervisor, but it also 
give one chance for dom0 to re-programme its polarity and trigger mode. 
Xiantao 

diff --git a/arch/x86/xen/pci.c b/arch/x86/xen/pci.c
index f999ad8..409bb66 100644
--- a/arch/x86/xen/pci.c
+++ b/arch/x86/xen/pci.c
@@ -80,17 +80,6 @@ void __init xen_setup_pirqs(void)
                return;
        }

-       /* Pre-allocate legacy irqs */
-       for (irq = 0; irq < NR_IRQS_LEGACY; irq++) {
-               int trigger, polarity;
-
-               if (acpi_get_override_irq(irq, &trigger, &polarity) == -1)
-                       continue;
-
-               xen_register_gsi(irq,
-                       trigger ? ACPI_LEVEL_SENSITIVE : ACPI_EDGE_SENSITIVE,
-                       polarity ? ACPI_ACTIVE_LOW : ACPI_ACTIVE_HIGH);
-       }
 }

 #ifdef CONFIG_PCI_MSI



Bastian Blank wrote:
> On Mon, Mar 15, 2010 at 12:30:32PM +0800, Zhang, Xiantao wrote:
>> Could you try the following patch ?  Currently, the GSI 0-15 's
>> polarity and trigger mode are determined by hypervisor, and maybe
>> hypervisor and dom0 has no agreement to determin them. Just follow
>> dom0's setting with this patch, and I think it maybe work for you.   
> 
> No, it does not. mp_register_gsi also disallows reprogramming of
> already 
> setup IO-APIC entries. But if I force it with the following hack, it
> works. So I would assume this a bug in the hypervisor to setup the GSI
> without knowing anything about it.
> 
> Bastian
> 
> diff -r 4152a3ce90a7 xen/arch/x86/mpparse.c
> --- a/xen/arch/x86/mpparse.c    Thu Mar 11 17:40:35 2010 +0000
> +++ b/xen/arch/x86/mpparse.c    Mon Mar 15 11:09:27 2010 +0100
> @@ -1143,5 +1143,5 @@
>         if ((1<<bit) & mp_ioapic_routing[ioapic].pin_programmed[idx])
>                 { Dprintk(KERN_DEBUG "Pin %d-%d already programmed\n",
>                         mp_ioapic_routing[ioapic].apic_id,
> ioapic_pin); +                if (mp_ioapic_routing[ioapic].apic_id
>                 == 8 && ioapic_pin == 14); else return -EEXIST;
>         }


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>