Received: from eggs.gnu.org ([2001:4830:134:3::10]:36960) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZcBrM-0003fF-83 for qemu-devel@nongnu.org; Wed, 16 Sep 2015 08:30:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZcBrG-0005iD-7n for qemu-devel@nongnu.org; Wed, 16 Sep 2015 08:30:48 -0400 Received: from mx1.redhat.com ([209.132.183.28]:57540) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZcBrF-0005hk-5Z for qemu-devel@nongnu.org; Wed, 16 Sep 2015 08:30:42 -0400 From: Paolo Bonzini Date: Wed, 16 Sep 2015 14:29:51 +0200 Message-Id: <1442406595-14296-21-git-send-email-pbonzini@redhat.com> In-Reply-To: <1442406595-14296-1-git-send-email-pbonzini@redhat.com> References: <1442406595-14296-1-git-send-email-pbonzini@redhat.com> Subject: [Qemu-devel] [PULL 20/24] include/exec: Move cputlb exec.c defs out List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Peter Crosthwaite , Peter Crosthwaite From: Peter Crosthwaite 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 Signed-off-by: Peter Crosthwaite Message-Id: Signed-off-by: Paolo Bonzini --- 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 f760f44..47ada31 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 72d4012..a3719b7 100644 --- a/include/exec/exec-all.h +++ b/include/exec/exec-all.h @@ -388,6 +388,24 @@ static inline void mmap_unlock(void) {} /* 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 */ -- 2.5.0