]> xenbits.xensource.com Git - libvirt.git/commitdiff
pci: Document virPCIGetPhysicalFunction()
authorAndrea Bolognani <abologna@redhat.com>
Wed, 25 May 2016 08:27:29 +0000 (10:27 +0200)
committerAndrea Bolognani <abologna@redhat.com>
Wed, 25 May 2016 08:38:01 +0000 (10:38 +0200)
src/util/virpci.c

index ca117db0c1a5470fe61ba2d5a1b62cae14a31d06..28da2948726ebb0767a381c7d7732020cce2431e 100644 (file)
@@ -2478,8 +2478,19 @@ virPCIGetDeviceAddressFromSysfsLink(const char *device_link)
     return bdf;
 }
 
-/*
- * Returns Physical function given a virtual function
+/**
+ * virPCIGetPhysicalFunction:
+ * @vf_sysfs_path: sysfs path for the virtual function
+ * @pf: where to store the physical function's address
+ *
+ * Given @vf_sysfs_path, this function will store the pointer
+ * to a newly-allocated virPCIDeviceAddress in @pf.
+ *
+ * @pf might be NULL if @vf_sysfs_path does not point to a
+ * virtual function. If it's not NULL, then it should be
+ * freed by the caller when no longer needed.
+ *
+ * Returns: >=0 on success, <0 on failure
  */
 int
 virPCIGetPhysicalFunction(const char *vf_sysfs_path,