[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 0/12] xen: MSI managment cleanups (Was: Re: [Xen-devel] [PATCH 1/3] pci/xen: Use xen_allocate_pirq_msi)



On Thu, 2011-02-17 at 14:52 +0000, Konrad Rzeszutek Wilk wrote:
> > All callers have this (type == MSIX) ? "msi-x" : "msi" construct,
> > differing only in their use of a "pcifront-" prefix. Something which
> > could be hoisted into the function perhaps?
> 
> I was thinking to defer this for a cleanup patch.
> > 
> > Another aside: I think there are other cleanups which could be made to
> > the various pirq allocation/mapping interfaces (of which there seem to
> > be too many, or at least their individual unique qualities are
> > indistinguishable by their names), I made a start on this at one point
> > since I wanted to get rid of the pirq_to_irq[nr_irqs] array, for obvious
> > reasons, but didn't finish it off. I'll hopefully revisit this soon.
> 
> Excellent. Looking forward to it.

Here is a first pass at some cleanups (based upon your series here).

I think the early parts of this series are reasonably uncontentious.

The second half refactors xen_create_msi_irq and xen_allocate_pirq_msi
with the aim of reducing confusion (i.e. without looking at the code
which of these is a dom0 only function and which is used by PV domU and
PVHVM domU?).

To do this I refactor into xen_allocate_pirq_msi, which simply gets a
free IRQ, and xen_bind_pirq_msi_to_irq, which performs the actual
binding and is common to all domain types.

Tested (lightly) as dom0, PV domU with MSI device passthrough and PVHVM
domU with MSI device passthrough.

In the future I hope to also tackle xen_map_irq_gsi and
xen_allocate_pirq.


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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.