[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v2 15/20] memory: Access MemoryRegion with MemOp sem
From: |
tony.nguyen |
Subject: |
[Qemu-devel] [PATCH v2 15/20] memory: Access MemoryRegion with MemOp semantics |
Date: |
Mon, 22 Jul 2019 15:50:41 +0000 |
To convert interfaces of MemoryRegion access, MEMOP_SIZE and
SIZE_MEMOP no-op stubs were introduced to change syntax while keeping
the existing semantics.
Now with interfaces converted, we fill the stubs and use MemOp
semantics.
Signed-off-by: Tony Nguyen <address@hidden>
---
include/exec/memop.h | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/include/exec/memop.h b/include/exec/memop.h
index 73f1bf7..dff6da2 100644
--- a/include/exec/memop.h
+++ b/include/exec/memop.h
@@ -24,8 +24,7 @@ typedef enum MemOp {
MO_BSWAP = 8, /* Host reverse endian. */
} MemOp;
-/* No-op while memory_region_dispatch_[read|write] is converted to MemOp */
-#define MEMOP_SIZE(op) (op) /* MemOp to size. */
-#define SIZE_MEMOP(ul) (ul) /* Size to MemOp. */
+#define MEMOP_SIZE(op) (1 << ((op) & MO_SIZE)) /* MemOp to size. */
+#define SIZE_MEMOP(ul) (ctzl(ul)) /* Size to MemOp. */
#endif
--
1.8.3.1
- [Qemu-devel] [PATCH v2 05/20] tcg: Move size+sign+endian from TCGMemOp to MemOp, (continued)
- [Qemu-devel] [PATCH v2 05/20] tcg: Move size+sign+endian from TCGMemOp to MemOp, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v2 06/20] tcg: Rename get_memop to get_tcgmemop, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v2 07/20] memory: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v2 09/20] hw/s390x: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v2 08/20] target/mips: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v2 10/20] hw/intc/armv7m_nic: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v2 11/20] hw/virtio: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v2 12/20] hw/vfio: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v2 13/20] exec: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v2 14/20] cputlb: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v2 15/20] memory: Access MemoryRegion with MemOp semantics,
tony.nguyen <=
- [Qemu-devel] [PATCH v2 16/20] memory: Single byte swap along the I/O path, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v2 17/20] cpu: TLB_FLAGS_MASK bit to force memory slow path, tony.nguyen, 2019/07/22
- [Qemu-devel] [PATCH v3 00/15] Invert Endian bit in SPARCv9 MMU TTE, tony.nguyen, 2019/07/25
- [Qemu-devel] [PATCH v3 02/15] memory: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/25
- [Qemu-devel] [PATCH v3 01/15] tcg: TCGMemOp is now accelerator independent MemOp, tony.nguyen, 2019/07/25
- [Qemu-devel] [PATCH v3 03/15] target/mips: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/25
- [Qemu-devel] [PATCH v3 04/15] hw/s390x: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/25
- [Qemu-devel] [PATCH v3 05/15] hw/intc/armv7m_nic: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/25
- [Qemu-devel] [PATCH v3 06/15] hw/virtio: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/25
- [Qemu-devel] [PATCH v3 07/15] hw/vfio: Access MemoryRegion with MemOp, tony.nguyen, 2019/07/25