From mboxrd@z Thu Jan 1 00:00:00 1970 From: Laszlo Ersek Subject: Re: PV passthrough of sibling igbvf's Date: Tue, 16 Oct 2012 17:04:20 +0200 Message-ID: <507D7774.2050902@redhat.com> References: <507D6D84.8050602@redhat.com> <507D7240.2010305@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <507D7240.2010305@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: Andrew Cooper Cc: Igor Mammedov , Drew Jones , "xen-devel@lists.xen.org" , Paolo Bonzini , Konrad Rzeszutek Wilk List-Id: xen-devel@lists.xenproject.org Hi, On 10/16/12 16:42, Andrew Cooper wrote: > I would hazard a guess that the real bug is trying to fake up 8 > individual virtual functions as an 8-fuction device, which seems like a > toolstack bug to me. I believe that comes from: >> The VPCI >> implementation of pciback_add_pci_dev() [drivers/xen/pciback/vpci.c] >> will assign these sibling functions to the same virtual slot. In other >> words, VFs that are siblings in dom0 end up as siblings in the PV domU. This grouping-together of virtual functions is the same in current upstream Linux: >> (Upstream path and function: "drivers/xen/xen-pciback/vpci.c", >> __xen_pcibk_add_pci_dev().) (+ match_slot()) >> >> This logic appears to date back to >> . A closer pointer into the changeset: http://xenbits.xensource.com/xen-unstable.hg/rev/5b433b4fca34#l16.85 The patch doesn't seem to justify the grouping specifically, thus I did not even try to refute it. Now that you point it out, match_slot() is probably insufficient grounds to group functions together. Maybe we should check *additionally* if the device being passed through is multi-function. I'll try it. Thanks! Laszlo