@samitouri / QOSamiQemu / commits / 736641b660

target/s390x: Replace legacy cpu_physical_memory_read/write() calls

cpu_physical_memory_read() and cpu_physical_memory_write() are legacy (see commit b7ecba0f6f6), replace by address_space_read() and address_space_write() respectively, accessing the per-vCPU address space instead of the global &address_space_memory one. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Reviewed-by: Jared Rossi <jrossi@linux.ibm.com> Message-Id: <20260616020839.19104-6-philmd@oss.qualcomm.com>

Philippe Mathieu-Daudé committed Oct 1, 2025 at 13:21 UTC 736641b66072ae1477dd8e47793efad64686d3cf
1 file changed +4 -2
target/s390x/diag.c
+4 -2
@@ -79,7 +79,8 @@ static void s390_ipl_read(CPUS390XState *env, uint64_t addr,
79 if (s390_is_pv()) {
80 s390_cpu_pv_mem_read(env_archcpu(env), 0, iplb, size);
81 } else {
82 - cpu_physical_memory_read(addr, iplb, size);
82 + address_space_read(cpu_get_address_space(env_cpu(env), 0), addr,
83 + MEMTXATTRS_UNSPECIFIED, iplb, size);
84 }
85 }
86
@@ -89,7 +90,8 @@ static void s390_ipl_write(CPUS390XState *env, uint64_t addr,
90 if (s390_is_pv()) {
91 s390_cpu_pv_mem_write(env_archcpu(env), 0, iplb, size);
92 } else {
92 - cpu_physical_memory_write(addr, iplb, size);
93 + address_space_write(cpu_get_address_space(env_cpu(env), 0), addr,
94 + MEMTXATTRS_UNSPECIFIED, iplb, size);
95 }
96 }
97