summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <philmd@linaro.org>2025-09-29 15:53:21 +0200
committerPhilippe Mathieu-Daudé <philmd@linaro.org>2025-10-07 05:03:56 +0200
commit5699f6a4409af985d45cd67a0695a97655fec8bf (patch)
treefbf15035da55e6ad5ec3637c497320edb9cba2cc
parent12a65afbbfd8bef09cafb1e0e7883c30ddc1c956 (diff)
downloadfocaccia-qemu-5699f6a4409af985d45cd67a0695a97655fec8bf.tar.gz
focaccia-qemu-5699f6a4409af985d45cd67a0695a97655fec8bf.zip
target/i386/nvmm: Inline cpu_physical_memory_rw() in nvmm_mem_callback
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20251002084203.63899-12-philmd@linaro.org>
-rw-r--r--target/i386/nvmm/nvmm-all.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/target/i386/nvmm/nvmm-all.c b/target/i386/nvmm/nvmm-all.c
index ed42425167..2e442baf4b 100644
--- a/target/i386/nvmm/nvmm-all.c
+++ b/target/i386/nvmm/nvmm-all.c
@@ -15,6 +15,7 @@
 #include "accel/accel-ops.h"
 #include "system/nvmm.h"
 #include "system/cpus.h"
+#include "system/memory.h"
 #include "system/runstate.h"
 #include "qemu/main-loop.h"
 #include "qemu/error-report.h"
@@ -516,7 +517,9 @@ nvmm_io_callback(struct nvmm_io *io)
 static void
 nvmm_mem_callback(struct nvmm_mem *mem)
 {
-    cpu_physical_memory_rw(mem->gpa, mem->data, mem->size, mem->write);
+    /* TODO: Get CPUState via mem->vcpu? */
+    address_space_rw(&address_space_memory, mem->gpa, MEMTXATTRS_UNSPECIFIED,
+                     mem->data, mem->size, mem->write);
 
     /* Needed, otherwise infinite loop. */
     current_cpu->vcpu_dirty = false;