[libvirt] [PATCH] expose SR IOV physical/virtual function relationships

Daniel P. Berrange berrange at redhat.com
Tue Dec 1 16:02:59 UTC 2009


On Tue, Dec 01, 2009 at 10:33:08AM -0500, Dave Allan wrote:
> Attached is a patch that exposes the relationships between physical and 
> virtual functions on SR IOV capable devices.
> 


> +            if (data->pci_dev.physical_function) {
> +                virBufferEscapeString(&buf, "    <physical_function>%s</physical_function>\n",
> +                                      data->pci_dev.physical_function);
> +            }
> +            if (data->pci_dev.num_virtual_functions > 0) {
> +                for (i = 0 ; i < data->pci_dev.num_virtual_functions ; i++) {
> +                    virBufferEscapeString(&buf, "    <virtual_function>%s</virtual_function>\n",
> +                                          data->pci_dev.virtual_functions[i]);
> +                }
> +            }


What is the actual content of those two new elements ?  Are they
the names of the corresponding device, suitble for a virNodeDevLooupByName() ?

REgards,
Daniel
-- 
|: Red Hat, Engineering, London   -o-   http://people.redhat.com/berrange/ :|
|: http://libvirt.org  -o-  http://virt-manager.org  -o-  http://ovirt.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505  -o-  F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|




More information about the libvir-list mailing list