From: Ian Campbell Subject: Re: [XenARM] XEN tools for ARM with Virtualization Extensions Date: Thu, 11 Jul 2013 18:18:23 +0100 Message-ID: <1373563103.12223.1.camel@hastur.hellion.org.uk> References: <1372237802.18901.115.camel@zakaz.uk.xensource.com> <1372265106.7337.107.camel@zakaz.uk.xensource.com> <1372350862.8976.35.camel@zakaz.uk.xensource.com> <51CC9398.4060301@linaro.org> <1373460637.5453.108.camel@hastur.hellion.org.uk> <1373494387.5453.142.camel@hastur.hellion.org.uk> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Eric Trudeau Cc: Julien Grall , "Stefano.Stabellini@citrix.com" , xen-devel List-Id: xen-devel@lists.xenproject.org On Thu, 2013-07-11 at 16:46 +0000, Eric Trudeau wrote: > > > >> > What functions should I call to implement XEN_DOMCTL_bind_pt_irq on > > > >> ARM? > > > >> > > > >> There's a function like route_irq_to_guest which we use to route IRQs to > > > >> dom0 during boot. In principal that could also be used to reroute an IRQ > > > >> to a guest, but I'm not sure how it will interact with the reassignment, > > > >> since in your case the IRQ starts off bound to dom0. Hopefully it's just > > > >> a small change to make it work for this case. > > > >> > > I have IRQs for devices being passed to ARM DomU guests now. Thanks for your > help. Excellent! Do you have any useful patches? > The IRQ mapping needs to be unmapped when the domU is destroyed and it is not > happening presently. I don't see a call to PHYSDEVOP_unmap_pirq or anything. > Should the mapped IRQs for a guest be unmapped when Xen destroys the domain > based on the IRQ rangeset? Where do you suggest doing this? > Or should the tools call an xc_physdev_unmap_pirq() when destroying the domain? > I would think it should be implicit in Hypervisor code to relinquish all resources of a > domain upon destruction... Having the hypervisor cleanup on destroy sounds sensible to me, x86 seems to call free_domain_pirqs from arch_domain_destroy. I think the unmap_pirq path is for hotunplug