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][RFC] pv-ops: fix shared irq device passthrough

To: 'Jeremy Fitzhardinge' <jeremy@xxxxxxxx>
Subject: RE: [Xen-devel] [PATCH][RFC] pv-ops: fix shared irq device passthrough
From: "Han, Weidong" <weidong.han@xxxxxxxxx>
Date: Fri, 30 Oct 2009 17:29:21 +0800
Accept-language: en-US
Acceptlanguage: en-US
Cc: "'xen-devel@xxxxxxxxxxxxxxxxxxx'" <xen-devel@xxxxxxxxxxxxxxxxxxx>, "'keir.fraser@xxxxxxxxxxxxx'" <keir.fraser@xxxxxxxxxxxxx>
Delivery-date: Fri, 30 Oct 2009 02:31:01 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <4AEA1D82.8060609@xxxxxxxx>
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: <715D42877B251141A38726ABF5CABF2C05509A75F3@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> <4AE60646.7050307@xxxxxxxx> <715D42877B251141A38726ABF5CABF2C05509A7C3A@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> <4AEA1D82.8060609@xxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcpY6wv4VEH634H0SIWkCZ9yI1YSogAUYWPQ
Thread-topic: [Xen-devel] [PATCH][RFC] pv-ops: fix shared irq device passthrough
Jeremy Fitzhardinge wrote:
> On 10/26/09 18:32, Han, Weidong wrote:
>>> Hm, not sure about this.  The logic in __setup_irq already looks
>>> pretty tortured, and I'd like to avoid touching it unless there's
>>> definitively a bug in there. 
>>> 
>>> I think the right question is whether probe_irq() is really doing
>>> the right test, and whether it could do something else instead?
>>> 
>> Totally agree. The better way is to change probe_irq, therefore
>> needn't touch kernel irq stuffs. probe_irq is just check if
>> desc->action == NULL or not. The code is there for a long long time
>> (from c/s 26 in linux-2.6.18-xen.hg). I don't know whether it can be
>> replaced.    
>> 
> 
> Could you look into it?  How many drivers do interrupt probing these
> days anyway?  I think we can safely not support ISA devices.
> 
>     J

All devices will call probing_irq in startup_pirq, which bind pirq to event 
channel. But now probing_irq always returns false, then all pirqs are not 
shareable. In my system, a PCI NIC, an USB controller and an IDE interface 
device share the same IRQ 18. Because above reason, pirq 18 is set not 
shareable. So when I hide the PCI NIC, and assign it to guest, it fails in 
guest_bind_pirq, therefore the PCI NIC in guest cannot work, even impact the 
devices who share the IRQ 18.

If don't want to change __setup_irq code like my patch does, current 
probing_irq is useless (always return false). The problem is there is almost no 
information in desc can be used in probing_irq if desc->action is NULL. Keir, 
do you have any ideas?

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