qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 00/10] hw/dma: Use dma_addr_t type definition when relevant
@ 2022-01-11 18:42 Philippe Mathieu-Daudé
  2022-01-11 18:43 ` [PATCH v3 01/10] stubs: Restrict fw_cfg to system emulation Philippe Mathieu-Daudé
                   ` (11 more replies)
  0 siblings, 12 replies; 20+ messages in thread
From: Philippe Mathieu-Daudé @ 2022-01-11 18:42 UTC (permalink / raw)
  To: qemu-devel
  Cc: qemu-block, Michael S. Tsirkin, David Hildenbrand,
	Philippe Mathieu-Daudé, Peter Xu, Paolo Bonzini

Since v2:
- Split meson patch restricting fw_cfg (Richard)
- Reorder pci_dma_map() docstring (Peter, Richard)
- Move QEMUSGList in previous patch (David)
- Have dma_buf_read/dma_buf_write return dma_addr_t (Peter)
- Drop 'propagate MemTxResult' patch (David)
- Added R-b tags

Since v1:
- Addressed David review comment (stick to dma_addr_t type)
- Addressed Peter review comment (incorrect doc string)

Hi,

This series aims to clarify a bit the DMA API, in particular the
'size' argument which is not clear enough (as we use multiple types
for it). This helps avoiding build failures on 32-bit host [*] (and
likely overflows calculation too IMO).

Some units using the DMA API are first removed from user-mode
emulation to avoid build failure (they shouldn't be there in
the first place).

Then some variables are renamed for clarity (no functional change).

Finally we replace misuses with dma_addr_t typedef.

Regards,

Phil.

[*] https://www.mail-archive.com/qemu-devel@nongnu.org/msg858825.html

Philippe Mathieu-Daudé (10):
  stubs: Restrict fw_cfg to system emulation
  hw/nvram: Restrict fw_cfg QOM interface to sysemu and tools
  hw/pci: Restrict pci-bus stub to sysemu
  hw/pci: Document pci_dma_map()
  hw/dma: Remove CONFIG_USER_ONLY check
  hw/rdma/rdma_utils: Rename rdma_pci_dma_map 'len' argument
  hw/scsi: Rename SCSIRequest::resid as 'residual'
  hw/dma: Fix format string issues using dma_addr_t
  hw/dma: Move ScatterGatherEntry / QEMUSGList declarations around
  hw/dma: Use dma_addr_t type definition when relevant

 hw/rdma/rdma_utils.h   |  2 +-
 include/hw/pci/pci.h   | 12 ++++++++++++
 include/hw/scsi/scsi.h |  4 ++--
 include/sysemu/dma.h   | 31 +++++++++++++++----------------
 hw/ide/ahci.c          |  2 +-
 hw/nvme/ctrl.c         |  2 +-
 hw/rdma/rdma_utils.c   | 14 +++++++-------
 hw/scsi/megasas.c      | 42 +++++++++++++++++++++++++-----------------
 hw/scsi/scsi-bus.c     | 10 +++++-----
 hw/scsi/scsi-disk.c    |  4 ++--
 softmmu/dma-helpers.c  | 34 ++++++++++++++++++----------------
 hw/nvram/meson.build   |  6 ++++--
 hw/rdma/trace-events   |  2 +-
 stubs/meson.build      |  4 ++--
 14 files changed, 96 insertions(+), 73 deletions(-)

-- 
2.34.1



^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2022-01-28  1:01 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-01-11 18:42 [PATCH v3 00/10] hw/dma: Use dma_addr_t type definition when relevant Philippe Mathieu-Daudé
2022-01-11 18:43 ` [PATCH v3 01/10] stubs: Restrict fw_cfg to system emulation Philippe Mathieu-Daudé
2022-01-12  9:08   ` David Hildenbrand
2022-01-28  0:38   ` Richard Henderson
2022-01-11 18:43 ` [PATCH v3 02/10] hw/nvram: Restrict fw_cfg QOM interface to sysemu and tools Philippe Mathieu-Daudé
2022-01-12  9:08   ` David Hildenbrand
2022-01-28  0:46   ` Richard Henderson
2022-01-11 18:43 ` [PATCH v3 03/10] hw/pci: Restrict pci-bus stub to sysemu Philippe Mathieu-Daudé
2022-01-11 18:43 ` [PATCH v3 04/10] hw/pci: Document pci_dma_map() Philippe Mathieu-Daudé
2022-01-11 18:43 ` [PATCH v3 05/10] hw/dma: Remove CONFIG_USER_ONLY check Philippe Mathieu-Daudé
2022-01-11 18:43 ` [PATCH v3 06/10] hw/rdma/rdma_utils: Rename rdma_pci_dma_map 'len' argument Philippe Mathieu-Daudé
2022-01-11 18:43 ` [PATCH v3 07/10] hw/scsi: Rename SCSIRequest::resid as 'residual' Philippe Mathieu-Daudé
2022-01-11 18:43 ` [PATCH v3 08/10] hw/dma: Fix format string issues using dma_addr_t Philippe Mathieu-Daudé
2022-01-11 18:43 ` [PATCH v3 09/10] hw/dma: Move ScatterGatherEntry / QEMUSGList declarations around Philippe Mathieu-Daudé
2022-01-12  9:10   ` David Hildenbrand
2022-01-28  0:48   ` Richard Henderson
2022-01-11 18:43 ` [PATCH v3 10/10] hw/dma: Use dma_addr_t type definition when relevant Philippe Mathieu-Daudé
2022-01-28  0:49   ` Richard Henderson
2022-01-12  1:23 ` [PATCH v3 00/10] " Peter Xu
2022-01-18  7:27 ` Philippe Mathieu-Daudé via

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).