[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v3 13/35] include/exec: Move cputlb exec.c defs out
From: |
Peter Crosthwaite |
Subject: |
[Qemu-devel] [PATCH v3 13/35] include/exec: Move cputlb exec.c defs out |
Date: |
Sat, 18 Jul 2015 02:40:23 -0700 |
Move the architecture agnostic function prototypes for exec.c out of
cputlb.h to exec-all.h. This allows hiding of the arch specific
cputlb.h from exec.c which should be getting close to having no
architecture specifics. Prepares support for multi-arch, which will have
a minimal cpu.h that services exec.c but not cputlb.h.
Reviewed-by: Richard Henderson <address@hidden>
Signed-off-by: Peter Crosthwaite <address@hidden>
---
Possible follow up (Paolo):
Since you are at it, tlb_protect_code/tlb_unprotect_code can also be
moved to this new header (and to translate-common.c).
---
exec.c | 1 -
include/exec/cputlb.h | 16 ----------------
include/exec/exec-all.h | 18 ++++++++++++++++++
3 files changed, 18 insertions(+), 17 deletions(-)
diff --git a/exec.c b/exec.c
index 14822c7..c37475a 100644
--- a/exec.c
+++ b/exec.c
@@ -49,7 +49,6 @@
#include "exec/cpu-all.h"
#include "qemu/rcu_queue.h"
#include "qemu/main-loop.h"
-#include "exec/cputlb.h"
#include "translate-all.h"
#include "exec/memory-internal.h"
diff --git a/include/exec/cputlb.h b/include/exec/cputlb.h
index 7ad5c9a..d454c00 100644
--- a/include/exec/cputlb.h
+++ b/include/exec/cputlb.h
@@ -25,23 +25,7 @@ void tlb_protect_code(ram_addr_t ram_addr);
void tlb_unprotect_code(ram_addr_t ram_addr);
void tlb_reset_dirty_range(CPUTLBEntry *tlb_entry, uintptr_t start,
uintptr_t length);
-void tlb_reset_dirty(CPUState *cpu, ram_addr_t start1, ram_addr_t length);
-void tlb_set_dirty(CPUState *cpu, target_ulong vaddr);
extern int tlb_flush_count;
-/* exec.c */
-void tb_flush_jmp_cache(CPUState *cpu, target_ulong addr);
-
-MemoryRegionSection *
-address_space_translate_for_iotlb(CPUState *cpu, hwaddr addr, hwaddr *xlat,
- hwaddr *plen);
-hwaddr memory_region_section_get_iotlb(CPUState *cpu,
- MemoryRegionSection *section,
- target_ulong vaddr,
- hwaddr paddr, hwaddr xlat,
- int prot,
- target_ulong *address);
-bool memory_region_is_unassigned(MemoryRegion *mr);
-
#endif
#endif
diff --git a/include/exec/exec-all.h b/include/exec/exec-all.h
index 4bc4340..cc19fc3 100644
--- a/include/exec/exec-all.h
+++ b/include/exec/exec-all.h
@@ -336,6 +336,24 @@ static inline tb_page_addr_t
get_page_addr_code(CPUArchState *env1, target_ulong
#else
/* cputlb.c */
tb_page_addr_t get_page_addr_code(CPUArchState *env1, target_ulong addr);
+
+void tlb_reset_dirty(CPUState *cpu, ram_addr_t start1, ram_addr_t length);
+void tlb_set_dirty(CPUState *cpu, target_ulong vaddr);
+
+/* exec.c */
+void tb_flush_jmp_cache(CPUState *cpu, target_ulong addr);
+
+MemoryRegionSection *
+address_space_translate_for_iotlb(CPUState *cpu, hwaddr addr, hwaddr *xlat,
+ hwaddr *plen);
+hwaddr memory_region_section_get_iotlb(CPUState *cpu,
+ MemoryRegionSection *section,
+ target_ulong vaddr,
+ hwaddr paddr, hwaddr xlat,
+ int prot,
+ target_ulong *address);
+bool memory_region_is_unassigned(MemoryRegion *mr);
+
#endif
/* vl.c */
--
1.9.1
- [Qemu-devel] [PATCH v3 03/35] translate-all: Move tcg_handle_interrupt() to -common, (continued)
- [Qemu-devel] [PATCH v3 03/35] translate-all: Move tcg_handle_interrupt() to -common, Peter Crosthwaite, 2015/07/18
- [Qemu-devel] [PATCH v3 04/35] tcg: split tcg_op_defs to -common, Peter Crosthwaite, 2015/07/18
- [Qemu-devel] [PATCH v3 05/35] tcg: Move tcg_tb_ptr to -common, Peter Crosthwaite, 2015/07/18
- [Qemu-devel] [PATCH v3 06/35] translate: move real_host_page setting to -common, Peter Crosthwaite, 2015/07/18
- [Qemu-devel] [PATCH v3 07/35] cpus: Listify cpu_list() function, Peter Crosthwaite, 2015/07/18
- [Qemu-devel] [PATCH v3 08/35] translate-common: Listify tcg_enabled(), Peter Crosthwaite, 2015/07/18
- [Qemu-devel] [PATCH v3 09/35] core: Convert tcg_enabled() users to tcg_(any|all)_enabled(), Peter Crosthwaite, 2015/07/18
- [Qemu-devel] [PATCH v3 10/35] exec-all: Move cpu_can_do_io() to qom/cpu.h, Peter Crosthwaite, 2015/07/18
- [Qemu-devel] [PATCH v3 11/35] cputlb: move CPU_LOOP() for tlb_reset() to exec.c, Peter Crosthwaite, 2015/07/18
- [Qemu-devel] [PATCH v3 12/35] cputlb: Change tlb_set_dirty() arg to cpu, Peter Crosthwaite, 2015/07/18
- [Qemu-devel] [PATCH v3 13/35] include/exec: Move cputlb exec.c defs out,
Peter Crosthwaite <=
- [Qemu-devel] [PATCH v3 14/35] cpu-common: Define tb_page_addr_t for everyone, Peter Crosthwaite, 2015/07/18
- [Qemu-devel] [PATCH v3 15/35] include/exec: Split target_long def to new header, Peter Crosthwaite, 2015/07/18
[Qemu-devel] [PATCH v3 17/35] monitor: uninclude cpu_ldst, Peter Crosthwaite, 2015/07/18
[Qemu-devel] [PATCH v3 16/35] cpu-defs: Allow multiple inclusions, Peter Crosthwaite, 2015/07/18
[Qemu-devel] [PATCH v3 19/35] target-*: cpu.h: Undefine core code symbols, Peter Crosthwaite, 2015/07/18
[Qemu-devel] [PATCH v3 18/35] target-*: Don't redefine cpu_exec(), Peter Crosthwaite, 2015/07/18