mirror_ubuntu-kernels/drivers/pci/endpoint/functions
Manivannan Sadhasivam 0d5d5738dc PCI: epf-mhi: Add support for DMA async read/write operation
The driver currently supports only the sync read/write operation i.e., it
waits for the DMA transfer to complete before returning to the caller
(MHI stack). But it is sub-optimal and defeats the actual purpose of using
DMA.

So let's add support for DMA async read/write operation by skipping the DMA
transfer completion and returning to the caller immediately. When the
completion actually happens later, the driver will be notified using the
DMA completion handler and in turn it will notify the caller using the
newly introduced callback in "struct mhi_ep_buf_info".

Since the DMA completion handler is invoked from the interrupt context, a
separate workqueue (epf_mhi->dma_wq) is used to notify the caller about the
completion of the transfer.

Acked-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Krzysztof Wilczyński <kw@linux.com>
Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
2023-12-14 11:58:53 +05:30
..
Kconfig PCI: endpoint: Add PCI Endpoint function driver for MHI bus 2023-06-23 15:05:49 -05:00
Makefile PCI: endpoint: Add PCI Endpoint function driver for MHI bus 2023-06-23 15:05:49 -05:00
pci-epf-mhi.c PCI: epf-mhi: Add support for DMA async read/write operation 2023-12-14 11:58:53 +05:30
pci-epf-ntb.c PCI: endpoint: Pass EPF device ID to the probe function 2023-06-23 15:05:03 -05:00
pci-epf-test.c PCI: endpoint: Pass EPF device ID to the probe function 2023-06-23 15:05:03 -05:00
pci-epf-vntb.c PCI: Fix typos in docs and comments 2023-08-25 08:15:38 -05:00