summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorj_mayer <j_mayer@c046a42c-6fe2-441c-8c8c-71466251a162>2007-04-07 11:21:28 +0000
committerj_mayer <j_mayer@c046a42c-6fe2-441c-8c8c-71466251a162>2007-04-07 11:21:28 +0000
commit9b3c35e0e6cea178b7c757300f9045258bc5cd10 (patch)
tree49a3eb5226c7928ada1d9314685028207972949d
parent80a34d67a5061ef1fbe8d8f77e866aa350f70959 (diff)
downloadqemu-9b3c35e0e6cea178b7c757300f9045258bc5cd10.tar.gz
cpu_get_phys_page_debug should return target_phys_addr_t
instead of target_ulong to be consistent. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2633 c046a42c-6fe2-441c-8c8c-71466251a162
-rw-r--r--cpu-all.h2
-rw-r--r--exec.c6
-rw-r--r--target-alpha/helper.c4
-rw-r--r--target-arm/helper.c4
-rw-r--r--target-i386/helper2.c4
-rw-r--r--target-m68k/translate.c2
-rw-r--r--target-mips/helper.c4
-rw-r--r--target-ppc/helper.c4
-rw-r--r--target-sh4/helper.c4
-rw-r--r--target-sparc/translate.c4
10 files changed, 20 insertions, 18 deletions
diff --git a/cpu-all.h b/cpu-all.h
index d2382857a5..2fc2f9a99d 100644
--- a/cpu-all.h
+++ b/cpu-all.h
@@ -799,7 +799,7 @@ void cpu_reset(CPUState *s);
/* Return the physical page corresponding to a virtual one. Use it
only for debugging because no protection checks are done. Return -1
if no page found. */
-target_ulong cpu_get_phys_page_debug(CPUState *env, target_ulong addr);
+target_phys_addr_t cpu_get_phys_page_debug(CPUState *env, target_ulong addr);
#define CPU_LOG_TB_OUT_ASM (1 << 0)
#define CPU_LOG_TB_IN_ASM (1 << 1)
diff --git a/exec.c b/exec.c
index 2467b62959..084b84409b 100644
--- a/exec.c
+++ b/exec.c
@@ -1030,7 +1030,8 @@ static void tb_reset_jump_recursive(TranslationBlock *tb)
#if defined(TARGET_HAS_ICE)
static void breakpoint_invalidate(CPUState *env, target_ulong pc)
{
- target_ulong addr, pd;
+ target_phys_addr_t addr;
+ target_ulong pd;
ram_addr_t ram_addr;
PhysPageDesc *p;
@@ -2574,7 +2575,8 @@ int cpu_memory_rw_debug(CPUState *env, target_ulong addr,
uint8_t *buf, int len, int is_write)
{
int l;
- target_ulong page, phys_addr;
+ target_phys_addr_t phys_addr;
+ target_ulong page;
while (len > 0) {
page = addr & TARGET_PAGE_MASK;
diff --git a/target-alpha/helper.c b/target-alpha/helper.c
index 0049c397ae..98200d9fb3 100644
--- a/target-alpha/helper.c
+++ b/target-alpha/helper.c
@@ -39,7 +39,7 @@ int cpu_alpha_handle_mmu_fault (CPUState *env, target_ulong address, int rw,
return 1;
}
-target_ulong cpu_get_phys_page_debug (CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug (CPUState *env, target_ulong addr)
{
return addr;
}
@@ -51,7 +51,7 @@ void do_interrupt (CPUState *env)
#else
-target_ulong cpu_get_phys_page_debug (CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug (CPUState *env, target_ulong addr)
{
return -1;
}
diff --git a/target-arm/helper.c b/target-arm/helper.c
index 242dd28f7b..111b84652f 100644
--- a/target-arm/helper.c
+++ b/target-arm/helper.c
@@ -126,7 +126,7 @@ int cpu_arm_handle_mmu_fault (CPUState *env, target_ulong address, int rw,
return 1;
}
-target_ulong cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
{
return addr;
}
@@ -441,7 +441,7 @@ int cpu_arm_handle_mmu_fault (CPUState *env, target_ulong address,
return 1;
}
-target_ulong cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
{
uint32_t phys_addr;
int prot;
diff --git a/target-i386/helper2.c b/target-i386/helper2.c
index dc6a5000ec..f05a284f96 100644
--- a/target-i386/helper2.c
+++ b/target-i386/helper2.c
@@ -578,7 +578,7 @@ int cpu_x86_handle_mmu_fault(CPUX86State *env, target_ulong addr,
return 1;
}
-target_ulong cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
{
return addr;
}
@@ -876,7 +876,7 @@ int cpu_x86_handle_mmu_fault(CPUX86State *env, target_ulong addr,
return 1;
}
-target_ulong cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
{
uint32_t pde_addr, pte_addr;
uint32_t pde, pte, paddr, page_offset, page_size;
diff --git a/target-m68k/translate.c b/target-m68k/translate.c
index 5d47c5469f..3b25635820 100644
--- a/target-m68k/translate.c
+++ b/target-m68k/translate.c
@@ -2738,7 +2738,7 @@ void cpu_dump_state(CPUState *env, FILE *f,
}
/* ??? */
-target_ulong cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
{
return addr;
}
diff --git a/target-mips/helper.c b/target-mips/helper.c
index d48c32b221..c23e9c6b37 100644
--- a/target-mips/helper.c
+++ b/target-mips/helper.c
@@ -141,12 +141,12 @@ static int get_physical_address (CPUState *env, target_ulong *physical,
}
#if defined(CONFIG_USER_ONLY)
-target_ulong cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
{
return addr;
}
#else
-target_ulong cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
{
target_ulong phys_addr;
int prot;
diff --git a/target-ppc/helper.c b/target-ppc/helper.c
index 1d973dc43b..69ed260f75 100644
--- a/target-ppc/helper.c
+++ b/target-ppc/helper.c
@@ -60,7 +60,7 @@ int cpu_ppc_handle_mmu_fault (CPUState *env, uint32_t address, int rw,
return 1;
}
-target_ulong cpu_get_phys_page_debug (CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug (CPUState *env, target_ulong addr)
{
return addr;
}
@@ -821,7 +821,7 @@ int get_physical_address (CPUState *env, mmu_ctx_t *ctx, target_ulong eaddr,
return ret;
}
-target_ulong cpu_get_phys_page_debug (CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug (CPUState *env, target_ulong addr)
{
mmu_ctx_t ctx;
diff --git a/target-sh4/helper.c b/target-sh4/helper.c
index 1839c96dde..1063ece2d8 100644
--- a/target-sh4/helper.c
+++ b/target-sh4/helper.c
@@ -53,7 +53,7 @@ int cpu_sh4_handle_mmu_fault(CPUState * env, target_ulong address, int rw,
return 1;
}
-target_ulong cpu_get_phys_page_debug(CPUState * env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug(CPUState * env, target_ulong addr)
{
return addr;
}
@@ -429,7 +429,7 @@ int cpu_sh4_handle_mmu_fault(CPUState * env, target_ulong address, int rw,
return tlb_set_page(env, address, physical, prot, is_user, is_softmmu);
}
-target_ulong cpu_get_phys_page_debug(CPUState * env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug(CPUState * env, target_ulong addr)
{
target_ulong physical;
int prot;
diff --git a/target-sparc/translate.c b/target-sparc/translate.c
index 0d71da3b86..e51a2e459c 100644
--- a/target-sparc/translate.c
+++ b/target-sparc/translate.c
@@ -3012,7 +3012,7 @@ void cpu_dump_state(CPUState *env, FILE *f,
}
#if defined(CONFIG_USER_ONLY)
-target_ulong cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
{
return addr;
}
@@ -3022,7 +3022,7 @@ extern int get_physical_address (CPUState *env, target_phys_addr_t *physical, in
int *access_index, target_ulong address, int rw,
int is_user);
-target_ulong cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
+target_phys_addr_t cpu_get_phys_page_debug(CPUState *env, target_ulong addr)
{
target_phys_addr_t phys_addr;
int prot, access_index;