]> git.ipfire.org Git - thirdparty/qemu.git/commitdiff
exec: Reduce tlb_set_dirty() declaration scope
authorPhilippe Mathieu-Daudé <philmd@linaro.org>
Thu, 14 Sep 2023 19:40:07 +0000 (21:40 +0200)
committerPhilippe Mathieu-Daudé <philmd@linaro.org>
Fri, 26 Apr 2024 13:28:11 +0000 (15:28 +0200)
tlb_set_dirty() is only used in accel/tcg/cputlb.c,
where it is defined. Declare it statically, removing
the stub.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Harsh Prateek Bora <harshpb@linux.ibm.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20240418192525.97451-11-philmd@linaro.org>

accel/stubs/tcg-stub.c
accel/tcg/cputlb.c
include/exec/exec-all.h

index 8a496a2a6fdcd852936039b08f3f84d7e4fd8b5d..dd890d6cf692ad52082af1d2d12c8604f03a2ac4 100644 (file)
@@ -18,10 +18,6 @@ void tb_flush(CPUState *cpu)
 {
 }
 
-void tlb_set_dirty(CPUState *cpu, vaddr vaddr)
-{
-}
-
 int probe_access_flags(CPUArchState *env, vaddr addr, int size,
                        MMUAccessType access_type, int mmu_idx,
                        bool nonfault, void **phost, uintptr_t retaddr)
index 93b1ca810bf42e03ac707205654018cc4b6fd145..e16d02a62c3f68897cc50133caadcbbe10dc708a 100644 (file)
@@ -1039,7 +1039,7 @@ static inline void tlb_set_dirty1_locked(CPUTLBEntry *tlb_entry,
 
 /* update the TLB corresponding to virtual page vaddr
    so that it is no longer dirty */
-void tlb_set_dirty(CPUState *cpu, vaddr addr)
+static void tlb_set_dirty(CPUState *cpu, vaddr addr)
 {
     int mmu_idx;
 
index 3e5350169154970c85c9cda459654b960d254256..9599e16a0999ed8f31c853c1dc0af575ba80447e 100644 (file)
@@ -654,7 +654,6 @@ static inline void mmap_unlock(void) {}
 #define WITH_MMAP_LOCK_GUARD()
 
 void tlb_reset_dirty(CPUState *cpu, ram_addr_t start1, ram_addr_t length);
-void tlb_set_dirty(CPUState *cpu, vaddr addr);
 void tlb_reset_dirty_range_all(ram_addr_t start, ram_addr_t length);
 
 MemoryRegionSection *