aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Hsieh <andrewhsieh@google.com>2012-06-21 23:03:44 -0700
committerandroid code review <noreply-gerritcodereview@google.com>2012-06-21 23:03:45 -0700
commita593847491224cfab9eb94b1e36c85333dc081da (patch)
treee680d838836d3cad018925130633fe5a3da7b9bc
parent870f03672ca3513fe5d666f425942fda651f30ec (diff)
parent342a01fc826881e6b12b7673c7d2c280295f4d9e (diff)
downloadexternal_qemu-a593847491224cfab9eb94b1e36c85333dc081da.zip
external_qemu-a593847491224cfab9eb94b1e36c85333dc081da.tar.gz
external_qemu-a593847491224cfab9eb94b1e36c85333dc081da.tar.bz2
Merge "[MIPS] Fix startup segfault in emulator64-mips"
-rw-r--r--android/main-emulator.c2
-rw-r--r--target-mips/op_helper.c8
2 files changed, 4 insertions, 6 deletions
diff --git a/android/main-emulator.c b/android/main-emulator.c
index ac4d2e9..0981a71 100644
--- a/android/main-emulator.c
+++ b/android/main-emulator.c
@@ -148,8 +148,6 @@ int main(int argc, char** argv)
avdArch = "arm";
D("Can't determine target AVD architecture: defaulting to %s\n", avdArch);
}
- if (!strcmp(avdArch, "mips"))
- force_32bit = 1; /* emulator64-mips segfaults currently, 4-19-2012 */
/* Find the architecture-specific program in the same directory */
emulatorPath = getTargetEmulatorPath(argv[0], avdArch, force_32bit);
diff --git a/target-mips/op_helper.c b/target-mips/op_helper.c
index 565cf94..a0c64f4 100644
--- a/target-mips/op_helper.c
+++ b/target-mips/op_helper.c
@@ -1870,7 +1870,7 @@ static unsigned long v2p_mmu(target_ulong addr, int is_user)
{
int index;
target_ulong tlb_addr;
- target_phys_addr_t physaddr;
+ unsigned long physaddr;
void *retaddr;
index = (addr >> TARGET_PAGE_BITS) & (CPU_TLB_SIZE - 1);
@@ -1892,12 +1892,12 @@ redo:
* to the address of simulation host (not the physical
* address of simulated OS.
*/
-target_phys_addr_t v2p(target_ulong ptr, int is_user)
+unsigned long v2p(target_ulong ptr, int is_user)
{
CPUState *saved_env;
int index;
target_ulong addr;
- target_phys_addr_t physaddr;
+ unsigned long physaddr;
saved_env = env;
env = cpu_single_env;
@@ -1907,7 +1907,7 @@ target_phys_addr_t v2p(target_ulong ptr, int is_user)
(addr & TARGET_PAGE_MASK), 0)) {
physaddr = v2p_mmu(addr, is_user);
} else {
- physaddr = (target_phys_addr_t)addr + env->tlb_table[is_user][index].addend;
+ physaddr = addr + env->tlb_table[is_user][index].addend;
}
env = saved_env;
return physaddr;