From: Peter Maydell <[email protected]> Rename cpu_phys_page_debug() and cpu_phys_page_attrs_debug() to cpu_phys_addr_debug() and cpu_phys_addr_attrs_debug().
Commit created with: sed -i -e 's/cpu_get_phys_page_debug/cpu_get_phys_addr_debug/g;s/cpu_get_phys_page_attrs_debug/cpu_get_phys_addr_attrs_debug/g' $(git grep -l cpu_get_phys_page) Signed-off-by: Peter Maydell <[email protected]> Reviewed-by: Philippe Mathieu-Daudé <[email protected]> Reviewed-by: Richard Henderson <[email protected]> Message-id: [email protected] Message-ID: <[email protected]> Signed-off-by: Philippe Mathieu-Daudé <[email protected]> --- include/hw/core/cpu.h | 8 ++++---- hw/core/cpu-system.c | 6 +++--- hw/i386/vapic.c | 4 ++-- hw/xtensa/sim.c | 2 +- hw/xtensa/xtfpga.c | 2 +- monitor/hmp-cmds.c | 2 +- plugins/api.c | 2 +- system/physmem.c | 2 +- target/sparc/mmu_helper.c | 6 +++--- target/xtensa/xtensa-semi.c | 2 +- 10 files changed, 18 insertions(+), 18 deletions(-) diff --git a/include/hw/core/cpu.h b/include/hw/core/cpu.h index c9fea797435..75e47768d43 100644 --- a/include/hw/core/cpu.h +++ b/include/hw/core/cpu.h @@ -739,7 +739,7 @@ enum CPUDumpFlags { void cpu_dump_state(CPUState *cpu, FILE *f, int flags); /** - * cpu_get_phys_page_attrs_debug: + * cpu_get_phys_addr_attrs_debug: * @cpu: The CPU to obtain the physical page address for. * @addr: The virtual address. * @attrs: Updated on return with the memory transaction attributes to use @@ -751,11 +751,11 @@ void cpu_dump_state(CPUState *cpu, FILE *f, int flags); * * Returns: Corresponding physical page address or -1 if no page found. */ -hwaddr cpu_get_phys_page_attrs_debug(CPUState *cpu, vaddr addr, +hwaddr cpu_get_phys_addr_attrs_debug(CPUState *cpu, vaddr addr, MemTxAttrs *attrs); /** - * cpu_get_phys_page_debug: + * cpu_get_phys_addr_debug: * @cpu: The CPU to obtain the physical page address for. * @addr: The virtual address. * @@ -764,7 +764,7 @@ hwaddr cpu_get_phys_page_attrs_debug(CPUState *cpu, vaddr addr, * * Returns: Corresponding physical page address or -1 if no page found. */ -hwaddr cpu_get_phys_page_debug(CPUState *cpu, vaddr addr); +hwaddr cpu_get_phys_addr_debug(CPUState *cpu, vaddr addr); /** cpu_asidx_from_attrs: * @cpu: CPU diff --git a/hw/core/cpu-system.c b/hw/core/cpu-system.c index 93dc861083c..05c126ecb6b 100644 --- a/hw/core/cpu-system.c +++ b/hw/core/cpu-system.c @@ -55,7 +55,7 @@ bool cpu_get_memory_mapping(CPUState *cpu, MemoryMappingList *list, return false; } -hwaddr cpu_get_phys_page_attrs_debug(CPUState *cpu, vaddr addr, +hwaddr cpu_get_phys_addr_attrs_debug(CPUState *cpu, vaddr addr, MemTxAttrs *attrs) { hwaddr paddr; @@ -73,11 +73,11 @@ hwaddr cpu_get_phys_page_attrs_debug(CPUState *cpu, vaddr addr, return paddr; } -hwaddr cpu_get_phys_page_debug(CPUState *cpu, vaddr addr) +hwaddr cpu_get_phys_addr_debug(CPUState *cpu, vaddr addr) { MemTxAttrs attrs = {}; - return cpu_get_phys_page_attrs_debug(cpu, addr, &attrs); + return cpu_get_phys_addr_attrs_debug(cpu, addr, &attrs); } int cpu_asidx_from_attrs(CPUState *cpu, MemTxAttrs attrs) diff --git a/hw/i386/vapic.c b/hw/i386/vapic.c index 3738031a055..225f19a75c7 100644 --- a/hw/i386/vapic.c +++ b/hw/i386/vapic.c @@ -173,7 +173,7 @@ static int find_real_tpr_addr(VAPICROMState *s, CPUX86State *env) * virtual address space for the APIC mapping. */ for (addr = 0xfffff000; addr >= 0x80000000; addr -= TARGET_PAGE_SIZE) { - paddr = cpu_get_phys_page_debug(cs, addr); + paddr = cpu_get_phys_addr_debug(cs, addr); if (paddr != APIC_DEFAULT_ADDRESS) { continue; } @@ -305,7 +305,7 @@ static int update_rom_mapping(VAPICROMState *s, CPUX86State *env, target_ulong i /* find out virtual address of the ROM */ rom_state_vaddr = s->rom_state_paddr + (ip & 0xf0000000); - paddr = cpu_get_phys_page_debug(cs, rom_state_vaddr); + paddr = cpu_get_phys_addr_debug(cs, rom_state_vaddr); if (paddr == -1) { return -1; } diff --git a/hw/xtensa/sim.c b/hw/xtensa/sim.c index 994460d0414..32eb16442f0 100644 --- a/hw/xtensa/sim.c +++ b/hw/xtensa/sim.c @@ -41,7 +41,7 @@ static uint64_t translate_phys_addr(void *opaque, uint64_t addr) { XtensaCPU *cpu = opaque; - return cpu_get_phys_page_debug(CPU(cpu), addr); + return cpu_get_phys_addr_debug(CPU(cpu), addr); } static void sim_reset(void *opaque) diff --git a/hw/xtensa/xtfpga.c b/hw/xtensa/xtfpga.c index 5e509216df8..256497e162d 100644 --- a/hw/xtensa/xtfpga.c +++ b/hw/xtensa/xtfpga.c @@ -192,7 +192,7 @@ static uint64_t translate_phys_addr(void *opaque, uint64_t addr) { XtensaCPU *cpu = opaque; - return cpu_get_phys_page_debug(CPU(cpu), addr); + return cpu_get_phys_addr_debug(CPU(cpu), addr); } static void xtfpga_reset(void *opaque) diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c index db92d6cb86b..b37a9985c0d 100644 --- a/monitor/hmp-cmds.c +++ b/monitor/hmp-cmds.c @@ -771,7 +771,7 @@ void hmp_gva2gpa(Monitor *mon, const QDict *qdict) return; } - gpa = cpu_get_phys_page_debug(cs, addr & TARGET_PAGE_MASK); + gpa = cpu_get_phys_addr_debug(cs, addr & TARGET_PAGE_MASK); if (gpa == -1) { monitor_printf(mon, "Unmapped\n"); } else { diff --git a/plugins/api.c b/plugins/api.c index 0c348a789b2..4b6fad49998 100644 --- a/plugins/api.c +++ b/plugins/api.c @@ -619,7 +619,7 @@ bool qemu_plugin_translate_vaddr(uint64_t vaddr, uint64_t *hwaddr) #ifdef CONFIG_SOFTMMU g_assert(current_cpu); - uint64_t res = cpu_get_phys_page_debug(current_cpu, vaddr); + uint64_t res = cpu_get_phys_addr_debug(current_cpu, vaddr); if (res == (uint64_t)-1) { return false; diff --git a/system/physmem.c b/system/physmem.c index c58d940e807..652b03ad5f5 100644 --- a/system/physmem.c +++ b/system/physmem.c @@ -4041,7 +4041,7 @@ int cpu_memory_rw_debug(CPUState *cpu, vaddr addr, MemTxResult res; page = addr & TARGET_PAGE_MASK; - phys_addr = cpu_get_phys_page_attrs_debug(cpu, page, &attrs); + phys_addr = cpu_get_phys_addr_attrs_debug(cpu, page, &attrs); asidx = cpu_asidx_from_attrs(cpu, attrs); /* if no physical page mapped, return an error */ if (phys_addr == -1) diff --git a/target/sparc/mmu_helper.c b/target/sparc/mmu_helper.c index 34b212a7aa5..e1abd520c49 100644 --- a/target/sparc/mmu_helper.c +++ b/target/sparc/mmu_helper.c @@ -366,20 +366,20 @@ void dump_mmu(CPUSPARCState *env) for (n = 0, va = 0; n < 256; n++, va += 16 * 1024 * 1024) { pde = mmu_probe(env, va, 2); if (pde) { - pa = cpu_get_phys_page_debug(cs, va); + pa = cpu_get_phys_addr_debug(cs, va); qemu_printf("VA: " TARGET_FMT_lx ", PA: " HWADDR_FMT_plx " PDE: " TARGET_FMT_lx "\n", va, pa, pde); for (m = 0, va1 = va; m < 64; m++, va1 += 256 * 1024) { pde = mmu_probe(env, va1, 1); if (pde) { - pa = cpu_get_phys_page_debug(cs, va1); + pa = cpu_get_phys_addr_debug(cs, va1); qemu_printf(" VA: " TARGET_FMT_lx ", PA: " HWADDR_FMT_plx " PDE: " TARGET_FMT_lx "\n", va1, pa, pde); for (o = 0, va2 = va1; o < 64; o++, va2 += 4 * 1024) { pde = mmu_probe(env, va2, 0); if (pde) { - pa = cpu_get_phys_page_debug(cs, va2); + pa = cpu_get_phys_addr_debug(cs, va2); qemu_printf(" VA: " TARGET_FMT_lx ", PA: " HWADDR_FMT_plx " PTE: " TARGET_FMT_lx "\n", diff --git a/target/xtensa/xtensa-semi.c b/target/xtensa/xtensa-semi.c index 28dfb29cbd3..9a6a9c8b4e4 100644 --- a/target/xtensa/xtensa-semi.c +++ b/target/xtensa/xtensa-semi.c @@ -215,7 +215,7 @@ void HELPER(simcall)(CPUXtensaState *env) uint32_t len_done = 0; while (len > 0) { - hwaddr paddr = cpu_get_phys_page_debug(cs, vaddr); + hwaddr paddr = cpu_get_phys_addr_debug(cs, vaddr); uint32_t page_left = TARGET_PAGE_SIZE - (vaddr & (TARGET_PAGE_SIZE - 1)); uint32_t io_sz = page_left < len ? page_left : len; -- 2.53.0
