aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Graf <agraf@suse.de>2012-02-21 19:01:11 +0100
committerAlexander Graf <agraf@suse.de>2012-03-15 13:12:10 +0100
commitd715ea961254512c6989e17edbfaf959aa7805b0 (patch)
tree7dcbc3e78ffd0a4d6ad015d72a5d42861423ce1b
parent32a2003af9cb0cb11b3992fd3248cb89752c53e9 (diff)
PPC: 405: Fix ppc405ep initialization
When trying to run a ppc405 guest, it segfaults quite quickly, trying to access timers that weren't initialized. Initialize them properly instead. Reported-by: Andreas Faerber <afaerber@suse.de> Signed-off-by: Alexander Graf <agraf@suse.de>
-rw-r--r--hw/ppc405_uc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/ppc405_uc.c b/hw/ppc405_uc.c
index 6f8342e0e7..89e5013b57 100644
--- a/hw/ppc405_uc.c
+++ b/hw/ppc405_uc.c
@@ -2471,6 +2471,8 @@ CPUPPCState *ppc405ep_init(MemoryRegion *address_space_mem,
ppc4xx_pob_init(env);
/* OBP arbitrer */
ppc4xx_opba_init(0xef600600);
+ /* Initialize timers */
+ ppc_booke_timers_init(env, sysclk, 0);
/* Universal interrupt controller */
irqs = g_malloc0(sizeof(qemu_irq) * PPCUIC_OUTPUT_NB);
irqs[PPCUIC_OUTPUT_INT] =