diff options
author | Wesley Sheng | 2018-12-10 17:12:24 +0800 |
---|---|---|
committer | Bjorn Helgaas | 2018-12-13 09:03:32 -0600 |
commit | f7eb7b8a4f72b0d9dea69b09f58185ffab97fd35 (patch) | |
tree | 44c8f6a837faf78d53bd2ad0308db0b3a5a2ea7f /drivers/pci/vpd.c | |
parent | 52d8db8e0cd7c28316514568fe5df0cfd4fa2075 (diff) |
switchtec: Add MRPC DMA mode support
MRPC normal mode requires the host to read the MRPC command status and
output data from BAR. This results in high latency responses from the
Memory Read TLP and potential Completion Timeout (CTO).
Add support for MRPC DMA mode, including related macro definitions and data
structures and code to:
* Retrieve MRPC DMA mode version from adapter firmware
* Allocate DMA buffer, register ISR, and enable DMA during init
* Check MRPC execution status and get execution results from DMA buffer
* Release DMA buffer and disable DMA function when unloading module
MRPC DMA mode is a new feature of firmware, and the driver will fall back
to MRPC normal mode if there is no support in the legacy firmware.
Add a module parameter, "use_dma_mrpc", to select between MRPC DMA mode and
MRPC normal mode. Since the driver automatically detects DMA support in
the firmware, this parameter is just for debugging and testing.
Include <linux/io-64-nonatomic-lo-hi.h> so that readq/writeq is replaced by
two readl/writel on systems that do not support it.
Signed-off-by: Wesley Sheng <wesley.sheng@microchip.com>
[bhelgaas: changelog, simplify dma_ver check]
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Logan Gunthorpe <logang@deltatee.com>
Diffstat (limited to 'drivers/pci/vpd.c')
0 files changed, 0 insertions, 0 deletions