From: Sander Eikelenboom Subject: Re: Xen pci-passthrough problem with pci-detach and pci-assignable-remove Date: Mon, 27 Jan 2014 17:42:05 +0100 Message-ID: <121674995.20140127174205@eikelenboom.it> References: <1447395332.20140110155157@eikelenboom.it> <20140110151218.GA20152@phenom.dumpdata.com> <1087166993.20140110165729@eikelenboom.it> <20140110161248.GE21360@phenom.dumpdata.com> <1010658460.20140110171623@eikelenboom.it> <20140110173809.GA19423@pegasus.dumpdata.com> <1889333978.20140124143602@eikelenboom.it> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1W7pGD-0007JF-5n for xen-devel@lists.xenproject.org; Mon, 27 Jan 2014 16:42:09 +0000 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: George Dunlap Cc: xen-devel List-Id: xen-devel@lists.xenproject.org Monday, January 27, 2014, 5:29:27 PM, you wrote: > On Fri, Jan 24, 2014 at 1:36 PM, Sander Eikelenboom > wrote: >> >> Friday, January 10, 2014, 6:38:10 PM, you wrote: >> >>>> > Wow. You just walked in a pile of bugs didn't you? And on Friday >>>> > nonethless. >>>> >>>> As usual ;-) >> >>> Ha! >>> ..snip.. >>>> >> [ 489.082358] [] ? mutex_spin_on_owner+0x38/0x45 >>>> >> [ 489.106272] [] ? schedule_preempt_disabled+0x6/0x9 >>>> >> [ 489.130158] [] ? __mutex_lock_slowpath+0x159/0x1b5 >>>> >> [ 489.154147] [] ? mutex_lock+0x16/0x25 >>>> >> [ 489.177890] [] ? pci_reset_function+0x26/0x4e >>>> >>>> > Yeah, that bug my RFC patchset (the one that does the slot/bus reset) should also fix. >>>> > I totally forgot about it ! >>>> >>>> Got a link to that patchset ? >> >>> https://lkml.org/lkml/2013/12/13/315 >> >>>> I at least could give it a spin .. you never know when fortune is on your side :-) >> >>> It is also at this git tree: >> >>> git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen.git and the >>> branch name is "devel/xen-pciback.slot_and_bus.v0". You will likely >>> want to merge it in your current Linus tree. >> >>> Thank you! >> >> >> Hi Konrad, >> >> Just got time to test this some more, when merging this branch *except* the last commit (9599a5ad38a3bb250e996ccb2cdaab6fb68aaacd) >> seems to help with my problem,i'm no capable of using: >> - xl pci-detach >> - xl pci-assignable-remove >> - echo "BDF" > /sys/bus/pci/drivers//bind > Out of curiosity, have you tried adding the -r option to pci-assignable-remove? > xl pci-assignable-add will store the original driver to which the > device was bound in xenstore; if you do "xl pci-assignable-remove -r" > it will attempt to re-bind it to that driver. > See more information here: > http://blog.xen.org/index.php/2012/06/04/xen-4-2-preview-xl-and-pci-pass-through/ Hi George, Yes i did, but since i seize the device at boot it was never bound to a device, so that isn't useful in this case (it doesn't know what to rebind to). But this problem seems fixed after applying the first 4 commits in konrad's pci reset branch at: http://git.kernel.org/cgit/linux/kernel/git/konrad/xen.git devel/xen-pciback.slot_and_bus.v0 Applying the last commit creates more problems than it fixes at the moment (hungtasks), so that one clearly need more polishing. So it's clearly a problem in the kernel and pciback specifically. -- Sander > -George