From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Cooper Subject: Re: xsa46-4.2.patch breaks PCI passthrough? Date: Wed, 1 May 2013 12:28:01 +0100 Message-ID: <5180FC41.2090108@citrix.com> References: <5180A825.4050108@crc.id.au> <5180F7CF.1050609@citrix.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------010607060207030302030606" Return-path: In-Reply-To: <5180F7CF.1050609@citrix.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: Steven Haigh Cc: xen-devel List-Id: xen-devel@lists.xenproject.org --------------010607060207030302030606 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit On 01/05/13 12:09, Andrew Cooper wrote: > On 01/05/13 06:29, Steven Haigh wrote: >> Hi all, >> >> I've had a report lodged against my packages that the patch provided for >> XSA46 against Xen 4.2.1 causes PCI passthru to break. >> >> It seems that 4.2.1 *without* the XSA46 patch works perfectly. 4.2.2 >> does not work. >> >> I added this patch in xen-4.2.1-6 of my RPMs (http://xen.crc.id.au) and >> the reporter has built the same SRPM with xsa46 patch removed and PCI >> passthrough works as intended. >> >> Reapplying the XSA46 patch causes it to break again. >> >> The bug report and logs can be found here: >> http://xen.crc.id.au/bugs/view.php?id=5 >> >> Has anyone come across this? >> > XSA-46 was to do with PCI passthrough of PV domains, and in particular > changing some of the rules regarding interrupts. > > One thing which is not clear from the bug report so far is what exactly > is failing with an EINVAL. The implication is that it is the toolstack > which is bailing before the VM is created. > > I will take a closer look at the two log files. > > ~Andrew > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xen.org > http://lists.xen.org/xen-devel Ok - please ignore my previous email somewhat. Xend is failing a xc.domain_irq_permission() call. As the toolstack side of things have not changed, it must be the changed in the hypervisor which are causing the issues. Can you please try the attached patch, and pass along xl dmesg in the failing case? ~Andrew --------------010607060207030302030606 Content-Type: text/x-patch; name="XSA-46-debug.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="XSA-46-debug.patch" diff --git a/xen/common/domctl.c b/xen/common/domctl.c index cbc8146..307848f 100644 --- a/xen/common/domctl.c +++ b/xen/common/domctl.c @@ -902,6 +902,8 @@ long do_domctl(XEN_GUEST_HANDLE(xen_domctl_t) u_domctl) else ret = pirq_deny_access(d, pirq); + printk("**DBG perms { %u, %d } = %d\n", pirq, allow, ret); + rcu_unlock_domain(d); } break; --------------010607060207030302030606 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --------------010607060207030302030606--