aboutsummaryrefslogtreecommitdiff
path: root/hw/nvme
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <philmd@redhat.com>2021-12-15 23:29:52 +0100
committerPhilippe Mathieu-Daudé <philmd@redhat.com>2021-12-31 01:05:27 +0100
commit1e5a3f8b2a976054da96cbbb9de6cbac7c2efb79 (patch)
tree85cdf06fcf5c3edd204010f5a19d7634eda56320 /hw/nvme
parent392e48af3468d7f8e49db33fdc9e28b5f99276ce (diff)
downloadqemu-1e5a3f8b2a976054da96cbbb9de6cbac7c2efb79.zip
qemu-1e5a3f8b2a976054da96cbbb9de6cbac7c2efb79.tar.gz
qemu-1e5a3f8b2a976054da96cbbb9de6cbac7c2efb79.tar.bz2
dma: Let dma_buf_read() take MemTxAttrs argument
Let devices specify transaction attributes when calling dma_buf_read(). Keep the default MEMTXATTRS_UNSPECIFIED in the few callers. Reviewed-by: Klaus Jensen <k.jensen@samsung.com> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211223115554.3155328-13-philmd@redhat.com>
Diffstat (limited to 'hw/nvme')
-rw-r--r--hw/nvme/ctrl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/nvme/ctrl.c b/hw/nvme/ctrl.c
index e1a531d..462f79a 100644
--- a/hw/nvme/ctrl.c
+++ b/hw/nvme/ctrl.c
@@ -1152,7 +1152,7 @@ static uint16_t nvme_tx(NvmeCtrl *n, NvmeSg *sg, uint8_t *ptr, uint32_t len,
if (dir == NVME_TX_DIRECTION_TO_DEVICE) {
residual = dma_buf_write(ptr, len, &sg->qsg, attrs);
} else {
- residual = dma_buf_read(ptr, len, &sg->qsg);
+ residual = dma_buf_read(ptr, len, &sg->qsg, attrs);
}
if (unlikely(residual)) {