qemu/include/exec
David Hildenbrand 7fd970a7d3 physmem: factor out direct access check into memory_region_supports_direct_access()
Let's factor the complete "directly accessible" check independent of
the "write" condition out so we can reuse it next.

We can now split up the checks RAM and ROMD check, so we really only check
for RAM DEVICE in case of RAM -- ROM DEVICE is neither RAM not RAM DEVICE.

Reviewed-by: Peter Xu <peterx@redhat.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
Link: https://lore.kernel.org/r/20250210084648.33798-4-david@redhat.com
Signed-off-by: Peter Xu <peterx@redhat.com>
2025-02-12 10:13:27 -05:00
..
abi_ptr.h exec: Declare abi_ptr type in its own 'abi_ptr.h' header 2024-04-26 17:03:05 +02:00
address-spaces.h exec/address-spaces.h: Remove unuseful 'exec/memory.h' include 2023-08-31 19:47:43 +02:00
breakpoint.h exec: Declare CPUBreakpoint/CPUWatchpoint type in 'breakpoint.h' header 2024-04-26 17:03:05 +02:00
cpu-all.h exec/cpu-all: Include 'cpu.h' earlier so MMU_USER_IDX is always defined 2024-12-20 17:44:57 +01:00
cpu-common.h accel/tcg: Move tcg_cflags_has/set() to 'exec/translation-block.h' 2024-12-20 17:44:57 +01:00
cpu-defs.h exec/cpu-defs: Remove unnecessary headers 2024-12-20 17:44:56 +01:00
cpu_ldst.h user: Introduce 'user/guest-host.h' header 2024-12-20 17:44:56 +01:00
cputlb.h exec: Restrict TCG specific declarations of 'cputlb.h' 2024-04-26 17:03:05 +02:00
exec-all.h accel/tcg: Declare cpu_loop_exit_requested() in 'exec/cpu-common.h' 2024-12-20 17:44:57 +01:00
gdbstub.h system: propagate Error to gdbserver_start (and other device setups) 2025-01-17 10:44:25 +00:00
helper-gen-common.h plugins: Remove plugin helpers 2024-04-30 16:12:05 -07:00
helper-gen.h tcg: Split helper-gen.h 2023-06-05 12:04:29 -07:00
helper-gen.h.inc tcg: Pass function pointer to tcg_gen_call* 2024-04-30 16:12:05 -07:00
helper-head.h.inc include/exec: Introduce fpst alias in helper-head.h.inc 2024-12-12 14:28:38 -06:00
helper-info.c.inc accel/tcg: Rename helper-head.h -> helper-head.h.inc 2024-04-26 15:31:37 +02:00
helper-proto-common.h plugins: Remove plugin helpers 2024-04-30 16:12:05 -07:00
helper-proto.h tcg: Split helper-proto.h 2023-06-05 12:04:29 -07:00
helper-proto.h.inc accel/tcg: Rename helper-head.h -> helper-head.h.inc 2024-04-26 15:31:37 +02:00
hwaddr.h bulk: Rename TARGET_FMT_plx -> HWADDR_FMT_plx 2023-01-18 11:14:34 +01:00
ioport.h exec/ioport: Add portio_list_set_enabled() 2024-02-14 06:09:32 -05:00
log.h include/exec/log: Do not reference QemuLogFile directly 2022-04-20 10:51:11 -07:00
memattrs.h memattrs: Check the size of MemTxAttrs 2025-01-23 11:50:53 +01:00
memop.h exec/memop: Remove unused memop_big_endian() helper 2024-10-15 11:55:09 -03:00
memopidx.h Normalize header guard symbol definition 2022-05-11 16:50:26 +02:00
memory-internal.h exec/memory: Expose memory_region_access_valid() 2023-01-09 13:50:13 +01:00
memory.h physmem: factor out direct access check into memory_region_supports_direct_access() 2025-02-12 10:13:27 -05:00
memory_ldst.h.inc bulk: Do not declare function prototypes using 'extern' keyword 2023-08-31 19:47:43 +02:00
memory_ldst_cached.h.inc exec/memory_ldst_cached: Use correct type size 2021-05-26 08:35:51 -07:00
memory_ldst_phys.h.inc exec/memory_ldst_phys: Use correct type sizes 2021-05-26 08:35:51 -07:00
mmu-access-type.h exec: Declare MMUAccessType type in 'mmu-access-type.h' header 2024-04-26 17:03:05 +02:00
page-protection.h accel/tcg: Declare mmap_[un]lock() in 'exec/page-protection.h' 2024-12-20 17:44:57 +01:00
page-vary.h bulk: Do not declare function prototypes using 'extern' keyword 2023-08-31 19:47:43 +02:00
plugin-gen.h plugins: Read mem_only directly from TB cflags 2024-05-15 08:55:18 +02:00
poison.h disas: Remove CRIS disassembler 2024-10-07 11:33:20 +02:00
ram_addr.h physmem: qemu_ram_alloc_from_fd extensions 2025-01-29 11:43:03 -03:00
ramblock.h Migration pull for 9.1 2024-04-23 21:32:22 -07:00
ramlist.h softmmu/physmem: fix memory leak in dirty_memory_extend() 2024-09-09 10:55:39 -04:00
replay-core.h replay: Extract core API to 'exec/replay-core.h' 2023-02-27 22:29:01 +01:00
target_long.h tcg: Define MO_TL 2023-10-22 16:34:21 -07:00
target_page.h softmmu: Introduce qemu_target_page_mask() helper 2023-06-23 02:54:44 -04:00
tb-flush.h accel/tcg: Declare tcg_flush_jmp_cache() in 'exec/tb-flush.h' 2023-11-07 12:13:27 +01:00
tlb-common.h tcg: Add tlb_fast_offset to TCGContext 2023-06-05 12:04:28 -07:00
translation-block.h accel/tcg: Move tcg_cflags_has/set() to 'exec/translation-block.h' 2024-12-20 17:44:57 +01:00
translator.h accel/tcg: Move gen_intermediate_code to TCGCPUOps.translate_core 2024-12-24 08:32:15 -08:00
tswap.h exec/tswap: Massage target_needs_bswap() definition 2024-10-15 11:55:09 -03:00
vaddr.h include/exec: Move vaddr defines to separate file 2024-01-29 07:06:03 +10:00