summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSegher Boessenkool <segher@kernel.crashing.org>2010-02-18 04:14:08 +0100
committerSegher Boessenkool <segher@kernel.crashing.org>2010-02-18 04:14:08 +0100
commit91a26a26aa7d24f34899aaeddc4779532b86cf2e (patch)
treee6a7118d6e77247e4407dc56605058183e8b5846
parent9aed2a09fee8e6f50a6657b3da85dc2793882037 (diff)
video: Init the IRQ position to something impossible
Without this, these IRQs trigger early, and WAL cannot handle that (it tries to handle all IRQs that are active, not only those that are enabled).
-rw-r--r--emu.c1
-rw-r--r--video.c6
-rw-r--r--video.h2
3 files changed, 9 insertions, 0 deletions
diff --git a/emu.c b/emu.c
index a9170a1..ac0da32 100644
--- a/emu.c
+++ b/emu.c
@@ -948,6 +948,7 @@ void emu(void)
read_rom(0);
board_init();
io_init();
+ video_init();
audio_init();
memset(reg, 0, sizeof reg);
diff --git a/video.c b/video.c
index a3e0e0f..7125011 100644
--- a/video.c
+++ b/video.c
@@ -471,3 +471,9 @@ void blit_screen(void)
blit_sprites(depth);
}
}
+
+void video_init(void)
+{
+ mem[0x2836] = 0xffff;
+ mem[0x2837] = 0xffff;
+}
diff --git a/video.h b/video.h
index 3f31661..a699d27 100644
--- a/video.h
+++ b/video.h
@@ -22,4 +22,6 @@ u16 video_load(u32 addr);
void blit_screen(void);
+void video_init(void);
+
#endif