From: Ian Jackson Subject: Re: [PATCH 1/2] libxl: Wait until QEMU removed the device before tearing it down Date: Fri, 14 Nov 2014 16:01:59 +0000 Message-ID: <21606.10103.850619.644934@mariner.uk.xensource.com> References: <1415661410-5191-1-git-send-email-boris.ostrovsky@oracle.com> <1415661410-5191-2-git-send-email-boris.ostrovsky@oracle.com> <21606.5282.659930.728522@mariner.uk.xensource.com> <54662004.6050702@oracle.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <54662004.6050702@oracle.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Boris Ostrovsky Cc: xen-devel@lists.xen.org, wei.liu2@citrix.com, ian.campbell@citrix.com, stefano.stabellini@eu.citrix.com List-Id: xen-devel@lists.xenproject.org Boris Ostrovsky writes ("Re: [PATCH 1/2] libxl: Wait until QEMU removed the device before tearing it down"): > But it doesn't help with the second part (the one that shows Linux > WARNING), because we still may try to reset the device before guest > kernel is done unloading the driver. Reproducing that problem is > probably dependent on the guest/driver: in this particular case the igb > driver does an IN instruction while unloading the driver and if that > instruction fails (which may happen if the device is gone from the POV > of toolstack) then it triggers the warning. Right. OK. Looking at the code, I think you have convinced about that. I will review the implementation in your patch now. > And I believe we still need part of the second patch --- the one that > removes call to xc_domain_irq_permission() for PV guests (after your > patch is applied): this call will fail because xc_physdev_unmap_pirq() > above it will cause hypervisor to do unmap_domain_pirq()->irq_deny_access() What call to xc_physdev_unmap_pirq ? I see one in the PV path. Ian.