mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 08:13:54 -06:00
pci: Let ld*_pci_dma() propagate MemTxResult
ld*_dma() returns a MemTxResult type. Do not discard it, return it to the caller. Update the few callers. Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211223115554.3155328-24-philmd@redhat.com>
This commit is contained in:
parent
6bebb27073
commit
4a63054bce
7 changed files with 60 additions and 53 deletions
|
@ -850,15 +850,14 @@ static inline MemTxResult pci_dma_write(PCIDevice *dev, dma_addr_t addr,
|
|||
DMA_DIRECTION_FROM_DEVICE, MEMTXATTRS_UNSPECIFIED);
|
||||
}
|
||||
|
||||
#define PCI_DMA_DEFINE_LDST(_l, _s, _bits) \
|
||||
static inline uint##_bits##_t ld##_l##_pci_dma(PCIDevice *dev, \
|
||||
dma_addr_t addr, \
|
||||
MemTxAttrs attrs) \
|
||||
{ \
|
||||
uint##_bits##_t val; \
|
||||
ld##_l##_dma(pci_get_address_space(dev), addr, &val, attrs); \
|
||||
return val; \
|
||||
} \
|
||||
#define PCI_DMA_DEFINE_LDST(_l, _s, _bits) \
|
||||
static inline MemTxResult ld##_l##_pci_dma(PCIDevice *dev, \
|
||||
dma_addr_t addr, \
|
||||
uint##_bits##_t *val, \
|
||||
MemTxAttrs attrs) \
|
||||
{ \
|
||||
return ld##_l##_dma(pci_get_address_space(dev), addr, val, attrs); \
|
||||
} \
|
||||
static inline MemTxResult st##_s##_pci_dma(PCIDevice *dev, \
|
||||
dma_addr_t addr, \
|
||||
uint##_bits##_t val, \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue