[libvirt] [PATCH 0/3 RFC] macvtap: Implement getPhysfn to support sending a port profile message for a VF to its PF

Dave Allan dallan at redhat.com
Tue Aug 2 01:16:09 UTC 2011


On Mon, Aug 01, 2011 at 04:56:58PM -0700, Roopa Prabhu wrote:
> This patch tries to fix getPhysFn in macvtap.c to get the physical 
> function(PF) of the direct attach interface, if the interface is a SR-IOV VF.
> It derives the PF/VF relationship from sysfs.
> 
> There is some code to do this in node device driver. But it is local
> to the node device driver . I did not see a clean way to use some of the
> node device stuff here. The node device driver looks at PCI capabilities to
> get the same information.

We should not have two implementations of this functionality in the
code.  Either the node device code should be made to use this version
or vice versa.  

> This implementation tries to not get into PCI capability details and   
> just looks at sysfs paths to derive the PF-VF relationship
> 
> This patch series implements the following 
> 01/3 - Add function to get the network interface name of a pci device
> 02/3 - Add functions to get sriov PF/VF relationship of a network interface
> 03/3 - macvtap: Fix getPhysfn to get the PF of a direct attach network interface
> 
> Signed-off-by: Roopa Prabhu <roprabhu at cisco.com>
> Signed-off-by: Christian Benvenuti <benve at cisco.com>
> Signed-off-by: David Wang <dwang2 at cisco.com>
> 
> --
> libvir-list mailing list
> libvir-list at redhat.com
> https://www.redhat.com/mailman/listinfo/libvir-list




More information about the libvir-list mailing list