dma: Let dma_buf_rw() propagate MemTxResult
authorPhilippe Mathieu-Daudé <philmd@redhat.com>
Wed, 15 Dec 2021 22:38:52 +0000 (23:38 +0100)
committerPhilippe Mathieu-Daudé <philmd@redhat.com>
Fri, 31 Dec 2021 00:05:27 +0000 (01:05 +0100)
commit292e13142d277c15bdd68331abc607e46628b7e1
tree757655100603847d4f17dd8f88707b8f4c995d35
parent1e5a3f8b2a976054da96cbbb9de6cbac7c2efb79
dma: Let dma_buf_rw() propagate MemTxResult

dma_memory_rw() returns a MemTxResult type. Do not discard
it, return it to the caller.

Since dma_buf_rw() was previously returning the QEMUSGList
size not consumed, add an extra argument where this size
can be stored.

Update the 2 callers.

Reviewed-by: Klaus Jensen <k.jensen@samsung.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20211223115554.3155328-14-philmd@redhat.com>
softmmu/dma-helpers.c