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] [PATCH 0/5] Add MSI support to XEN

To: "Neil Turton" <nturton@xxxxxxxxxxxxxx>
Subject: RE: [Xen-devel] [PATCH 0/5] Add MSI support to XEN
From: "Shan, Haitao" <haitao.shan@xxxxxxxxx>
Date: Thu, 3 Apr 2008 20:11:55 +0800
Cc: Keir Fraser <Keir.Fraser@xxxxxxxxxxxx>, xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>, "Li, Xin B" <xin.b.li@xxxxxxxxx>, "Tian, Kevin" <kevin.tian@xxxxxxxxx>, "Jiang, Yunhong" <yunhong.jiang@xxxxxxxxx>
Delivery-date: Thu, 03 Apr 2008 05:20:56 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <47F39E76.8020805@xxxxxxxxxxxxxx>
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/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <823A93EED437D048963A3697DB0E35DE0139CE15@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> <47F39E76.8020805@xxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AciU0oBZmWeHZsxDQgSmv3Rj5p+TNAAr79cQ
Thread-topic: [Xen-devel] [PATCH 0/5] Add MSI support to XEN
Hi, Neil

Thanks for trying the patches. The problem is caused by incompatibility between 
Xen and Dom0 kernel.
Pci_vector_resources is to calculate available vectors. Xen assigns vector by 
start with vector 0x20 and offset = 0. This will confuse the code in 
pci_vector_resources.
Maybe we should replace the function with a hypercall to acquire the number of 
available vectors. 
How do you think about it, Keir?
Thanks!

Shan Haitao

-----Original Message-----
From: Neil Turton [mailto:nturton@xxxxxxxxxxxxxx] 
Sent: 2008年4月2日 22:56
To: Shan, Haitao
Cc: Keir Fraser; xen-devel; Tian, Kevin; Jiang, Yunhong; Li, Xin B
Subject: Re: [Xen-devel] [PATCH 0/5] Add MSI support to XEN

I tried this patch and MSI seems to work fine with a driver in DOM0.  It
didn't work with MSI-X though because pci_vector_resources returned 8
and I have 10 MSI capable devices in the machine.  I've only got 6
Phys-irq interrupts listed in /proc/interrupts so I'd expect there to be
more vectors free.  I applied the debugging patch below and got the
following output.

diff -r 9bb373519b68 arch/i386/pci/irq-xen.c
--- a/arch/i386/pci/irq-xen.c   Tue Apr 01 14:15:23 2008 +0100
+++ b/arch/i386/pci/irq-xen.c   Wed Apr 02 13:19:05 2008 +0100
@@ -1192,6 +1192,7 @@ int pci_vector_resources(int last, int n
        int offset = (last % 8);

        while (next < FIRST_SYSTEM_VECTOR) {
+               printk("next=%d count=%d\n", next, count);
                next += 8;
 #ifdef CONFIG_X86_64
                if (next == IA32_SYSCALL_VECTOR)

[pci_vector_resources(176, 1) called]
next=176 count=1
next=184 count=2
next=192 count=3
next=200 count=4
next=208 count=5
next=216 count=6
next=224 count=7
next=232 count=8
[pci_vector_resources returned 8]

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

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