summaryrefslogtreecommitdiff
path: root/hw/ppc_prep.c
diff options
context:
space:
mode:
authorbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2004-05-21 12:59:32 +0000
committerbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2004-05-21 12:59:32 +0000
commit9fddaa0c0cabb610947146a79b4a9a38b0a216e5 (patch)
tree0fdea73fdd2dab9437c23efa4ffbc3e22e2be036 /hw/ppc_prep.c
parent4a0fb71e67df4774d79eb788f0d1bd7a78801e6d (diff)
downloadqemu-9fddaa0c0cabb610947146a79b4a9a38b0a216e5.tar.gz
PowerPC merge: real time TB and decrementer - faster and simpler exception handling (Jocelyn Mayer)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@841 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'hw/ppc_prep.c')
-rw-r--r--hw/ppc_prep.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/hw/ppc_prep.c b/hw/ppc_prep.c
index f64649cf5a..05783992b8 100644
--- a/hw/ppc_prep.c
+++ b/hw/ppc_prep.c
@@ -24,6 +24,9 @@
#include "vl.h"
#include "m48t59.h"
+/* XXX: move all TB related stuff in ppc_prep.c and suppress ppc.c ? */
+ppc_tb_t *cpu_ppc_tb_init (CPUPPCState *env, uint32_t freq);
+
//#define HARD_DEBUG_PPC_IO
//#define DEBUG_PPC_IO
@@ -663,7 +666,6 @@ static void VGA_printf (uint8_t *s)
static void VGA_init (void)
{
/* Basic VGA init, inspired by plex86 VGAbios */
- printf("Init VGA...\n");
#if 1
/* switch to color mode and enable CPU access 480 lines */
PPC_io_writeb(PPC_IO_BASE + 0x3C2, 0xC3);
@@ -725,7 +727,6 @@ void PPC_init_hw (/*CPUPPCState *env,*/ uint32_t mem_size,
* if a decrementer exception is pending when it enables msr_ee,
* it's not ready to handle it...
*/
- env->decr = 0xFFFFFFFF;
p = phys_ram_base + kernel_addr;
#if !defined (USE_OPEN_FIRMWARE)
/* Let's register the whole memory available only in supervisor mode */
@@ -948,6 +949,8 @@ void ppc_prep_init(int ram_size, int vga_ram_size, int boot_device,
}
}
+ cpu_ppc_tb_init(cpu_single_env, 100UL * 1000UL * 1000UL);
+
/* init basic PC hardware */
vga_initialize(ds, phys_ram_base + ram_size, ram_size,
vga_ram_size, 0);