]> rtime.felk.cvut.cz Git - can-eth-gw-linux.git/blobdiff - Documentation/ABI/testing/sysfs-bus-pci
Merge tag 'for-3.8' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci
[can-eth-gw-linux.git] / Documentation / ABI / testing / sysfs-bus-pci
index dff1f48d252d8f0d36aa31cccf6514cb02b3d333..1ce5ae329c048fa1f9c84523592d5bfc34c22614 100644 (file)
@@ -222,3 +222,37 @@ Description:
                satisfied too.  Reading this attribute will show the current
                value of d3cold_allowed bit.  Writing this attribute will set
                the value of d3cold_allowed bit.
+
+What:          /sys/bus/pci/devices/.../sriov_totalvfs
+Date:          November 2012
+Contact:       Donald Dutile <ddutile@redhat.com>
+Description:
+               This file appears when a physical PCIe device supports SR-IOV.
+               Userspace applications can read this file to determine the
+               maximum number of Virtual Functions (VFs) a PCIe physical
+               function (PF) can support. Typically, this is the value reported
+               in the PF's SR-IOV extended capability structure's TotalVFs
+               element.  Drivers have the ability at probe time to reduce the
+               value read from this file via the pci_sriov_set_totalvfs()
+               function.
+
+What:          /sys/bus/pci/devices/.../sriov_numvfs
+Date:          November 2012
+Contact:       Donald Dutile <ddutile@redhat.com>
+Description:
+               This file appears when a physical PCIe device supports SR-IOV.
+               Userspace applications can read and write to this file to
+               determine and control the enablement or disablement of Virtual
+               Functions (VFs) on the physical function (PF). A read of this
+               file will return the number of VFs that are enabled on this PF.
+               A number written to this file will enable the specified
+               number of VFs. A userspace application would typically read the
+               file and check that the value is zero, and then write the number
+               of VFs that should be enabled on the PF; the value written
+               should be less than or equal to the value in the sriov_totalvfs
+               file. A userspace application wanting to disable the VFs would
+               write a zero to this file. The core ensures that valid values
+               are written to this file, and returns errors when values are not
+               valid.  For example, writing a 2 to this file when sriov_numvfs
+               is not 0 and not 2 already will return an error. Writing a 10
+               when the value of sriov_totalvfs is 8 will return an error.