[PATCH 0/1] pci: pass along the return value of dma_memory_rw

Klaus Jensen posted 1 patch 4 years, 6 months ago
Test asan passed
Test checkpatch passed
Test FreeBSD passed
Test docker-mingw@fedora passed
Test docker-clang@ubuntu passed
Test docker-quick@centos7 passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20191011070141.188713-1-its@irrelevant.dk
Maintainers: Marcel Apfelbaum <marcel.apfelbaum@gmail.com>, "Michael S. Tsirkin" <mst@redhat.com>
include/hw/pci/pci.h | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
[PATCH 0/1] pci: pass along the return value of dma_memory_rw
Posted by Klaus Jensen 4 years, 6 months ago
Hi,

While working on fixing the emulated nvme device to pass more tests in
the blktests suite, I discovered that the pci_dma_rw function ignores
the return value of dma_memory_rw.

The nvme device needs to handle DMA errors gracefully in order to pass
the block/011 test ("disable PCI device while doing I/O") in the
blktests suite. This is only possible if the device knows if the DMA
transfer was successful or not.

I can't see what the reason for ignoring the return value would be. But
if there is a good reason, please enlighten me :)


Klaus Jensen (1):
  pci: pass along the return value of dma_memory_rw

 include/hw/pci/pci.h | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

-- 
2.23.0


Re: [PATCH 0/1] pci: pass along the return value of dma_memory_rw
Posted by Klaus Birkelund 4 years, 6 months ago
On Fri, Oct 11, 2019 at 09:01:40AM +0200, Klaus Jensen wrote:
> Hi,
> 
> While working on fixing the emulated nvme device to pass more tests in
> the blktests suite, I discovered that the pci_dma_rw function ignores
> the return value of dma_memory_rw.
> 
> The nvme device needs to handle DMA errors gracefully in order to pass
> the block/011 test ("disable PCI device while doing I/O") in the
> blktests suite. This is only possible if the device knows if the DMA
> transfer was successful or not.
> 
> I can't see what the reason for ignoring the return value would be. But
> if there is a good reason, please enlighten me :)
> 
> 
> Klaus Jensen (1):
>   pci: pass along the return value of dma_memory_rw
> 
>  include/hw/pci/pci.h | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> -- 
> 2.23.0
> 

Gentle ping.

https://patchwork.kernel.org/patch/11184911/