Back to home page

OSCL-LXR

 
 

    


0001 .. SPDX-License-Identifier: GPL-2.0
0002 
0003 =====================================
0004 Driver for PCI Endpoint Test Function
0005 =====================================
0006 
0007 This driver should be used as a host side driver if the root complex is
0008 connected to a configurable PCI endpoint running ``pci_epf_test`` function
0009 driver configured according to [1]_.
0010 
0011 The "pci_endpoint_test" driver can be used to perform the following tests.
0012 
0013 The PCI driver for the test device performs the following tests:
0014 
0015         #) verifying addresses programmed in BAR
0016         #) raise legacy IRQ
0017         #) raise MSI IRQ
0018         #) raise MSI-X IRQ
0019         #) read data
0020         #) write data
0021         #) copy data
0022 
0023 This misc driver creates /dev/pci-endpoint-test.<num> for every
0024 ``pci_epf_test`` function connected to the root complex and "ioctls"
0025 should be used to perform the above tests.
0026 
0027 ioctl
0028 -----
0029 
0030  PCITEST_BAR:
0031               Tests the BAR. The number of the BAR to be tested
0032               should be passed as argument.
0033  PCITEST_LEGACY_IRQ:
0034               Tests legacy IRQ
0035  PCITEST_MSI:
0036               Tests message signalled interrupts. The MSI number
0037               to be tested should be passed as argument.
0038  PCITEST_MSIX:
0039               Tests message signalled interrupts. The MSI-X number
0040               to be tested should be passed as argument.
0041  PCITEST_SET_IRQTYPE:
0042               Changes driver IRQ type configuration. The IRQ type
0043               should be passed as argument (0: Legacy, 1:MSI, 2:MSI-X).
0044  PCITEST_GET_IRQTYPE:
0045               Gets driver IRQ type configuration.
0046  PCITEST_WRITE:
0047               Perform write tests. The size of the buffer should be passed
0048               as argument.
0049  PCITEST_READ:
0050               Perform read tests. The size of the buffer should be passed
0051               as argument.
0052  PCITEST_COPY:
0053               Perform read tests. The size of the buffer should be passed
0054               as argument.
0055 
0056 .. [1] Documentation/PCI/endpoint/function/binding/pci-test.rst