summaryrefslogtreecommitdiffstats
path: root/hw/mips_malta.c
diff options
context:
space:
mode:
authorths2007-04-06 01:12:54 +0200
committerths2007-04-06 01:12:54 +0200
commitfb82fea06403d7d7b064b9ef7acc9c62dcd52850 (patch)
tree15550d9cfc8e9fc43dc449ef963497a334d69bf4 /hw/mips_malta.c
parentFix alpha target compilation on 32 bits hosts. (diff)
downloadqemu-fb82fea06403d7d7b064b9ef7acc9c62dcd52850.tar.gz
qemu-fb82fea06403d7d7b064b9ef7acc9c62dcd52850.tar.xz
qemu-fb82fea06403d7d7b064b9ef7acc9c62dcd52850.zip
Clear BEV and ERL for the fake bootloader.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2609 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'hw/mips_malta.c')
-rw-r--r--hw/mips_malta.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/hw/mips_malta.c b/hw/mips_malta.c
index 2f3288bd7f..97707c1166 100644
--- a/hw/mips_malta.c
+++ b/hw/mips_malta.c
@@ -654,8 +654,10 @@ static void main_cpu_reset(void *opaque)
/* The bootload does not need to be rewritten as it is located in a
read only location. The kernel location and the arguments table
location does not change. */
- if (env->kernel_filename)
+ if (env->kernel_filename) {
+ env->CP0_Status &= ~((1 << CP0St_BEV) | (1 << CP0St_ERL));
load_kernel (env);
+ }
}
static
@@ -709,6 +711,7 @@ void mips_malta_init (int ram_size, int vga_ram_size, int boot_device,
env->kernel_cmdline = kernel_cmdline;
env->initrd_filename = initrd_filename;
kernel_entry = load_kernel(env);
+ env->CP0_Status &= ~((1 << CP0St_BEV) | (1 << CP0St_ERL));
write_bootloader(env, bios_offset, kernel_entry);
} else {
snprintf(buf, sizeof(buf), "%s/%s", bios_dir, BIOS_FILENAME);