]> www.infradead.org Git - users/dwmw2/linux.git/commit
PCI: endpoint: test: Use pci_epc_mem_map/unmap()
authorDamien Le Moal <dlemoal@kernel.org>
Sat, 12 Oct 2024 11:32:45 +0000 (20:32 +0900)
committerManivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Wed, 16 Oct 2024 16:55:34 +0000 (22:25 +0530)
commit08cac1006bfcc35fe363055a40e05d5410cdf010
tree9f873e649cfe3b7c6ddef81ceafb86f44e9e8581
parent6067ccf36fbc8a5e5a32f15b267e3dc6aa6e7eb4
PCI: endpoint: test: Use pci_epc_mem_map/unmap()

Modify the endpoint test driver to use the functions pci_epc_mem_map()
and pci_epc_mem_unmap() for the read, write and copy tests. For each
test case, the transfer (dma or mmio) are executed in a loop to ensure
that potentially partial mappings returned by pci_epc_mem_map() are
correctly handled.

Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
Reviewed-by: Niklas Cassel <cassel@kernel.org>
Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Link: https://lore.kernel.org/r/20241012113246.95634-6-dlemoal@kernel.org
Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
drivers/pci/endpoint/functions/pci-epf-test.c