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] Dynamic-irq's in HVM domains

To: "Ian Campbell" <Ian.Campbell@xxxxxxxxxx>
Subject: RE: [Xen-devel] Dynamic-irq's in HVM domains
From: "James Harper" <james.harper@xxxxxxxxxxxxxxxx>
Date: Fri, 30 Nov 2007 20:02:08 +1100
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Fri, 30 Nov 2007 01:02:45 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <1196410794.14204.18.camel@xxxxxxxxxxxxxxxxxxxxx>
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: <AEC6C66638C05B468B556EA548C1A77D0131A1B1@trantor> <AEC6C66638C05B468B556EA548C1A77D0131A2D0@trantor> <1196410794.14204.18.camel@xxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcgzKentfK4Og61uQSGRudSOWaD3xgABIpPQ
Thread-topic: [Xen-devel] Dynamic-irq's in HVM domains
> > > 'cat /proc/interrupts' in a Linux PV domain shows interrupts
starting
> > > at 256 and labelled as 'Dynamic-irq'. Are these available in a HVM
> > > domain eg under Windows?
> 
> On Fri, 2007-11-30 at 13:29 +1100, James Harper wrote:
> > I'm really desperate for an answer to this question...
> 
> Dynamic IRQs are just a convenient Linux interface used to represent
> event channels in order that they can be used with the regular IRQ
> subsystem. Although I think they were added by Xen folk I don't think
> there's anything Xen specific or special about them.
> 
> Event channels are (of course) exposed to HVM guests. The Linux
> PV-on-HVM drivers export them itself via their own parallel
> interrupt-like subsystem because not all the native versions supported
> by the PV-on-HVM drivers have dynamic IRQs. See evtchn_interrupt() and
> the other code in unmodified_drivers/linux-2.6/platform-pci/evtchn.c
> 
> Perhaps Windows has a similar concept to dynamic IRQs in its IRQ
> subsystem, I'm afraid not being a Windows type I have no idea about
> that. You can still use event channels outside of the regular windows
> IRQ subsystem though, as demonstrated above.

I'm doing that... see below as to why it doesn't quite meet my needs...

> 
> > Failing that, can I use physical IRQ's in a HVM domain to bind to?
Eg
> > nothing is using IRQ 26, can I use that with bind_pirq? The only
docs I
> > can find says 'Furthermore the calling domain must be sufficiently
> > privileged.', but I'm not sure how privileged 'sufficiently' means
in
> > this context.
> 
> I doubt that will work, I expect privileged means either domain 0 or a
> domain with a PCI passthrough device attached...
> 

Hmmm... the problem I am facing is that I found 'class drivers' too
limiting in Windows, so I am trying to go down the scsi 'miniport'
route. There are 2 problems with that... the first is that due to a bug
in the Windows miniport implementation, you have to assign a hardware
i/o or memory resource to the driver. I have overcome that without too
much pain though.

The second problem is that the 'event complete' notification for
scsiport has to occur within the context of the scsi miniport driver
itself. I just can't use the event channel notification and call
'ScsiPortNotification' from there to say that the operation is complete
(it just gets ignored). And of course being Windows, I can't go poking
around in the source to see if there is another way to do it.

The only way I can think of is to assign an IRQ to the miniport driver,
and somehow get that to fire. If I can do that, everything will work
just fine.

I made the assumption that 'Dynamic-irq' is the same as virq... if not,
what is a virq? It appears to be something that the hypervisor is aware
of as there is a hypercall to bind to one.

Thanks for the response.

James

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