2005-09-03 15:56:11 -07:00
|
|
|
#include <linux/init.h>
|
|
|
|
#include <asm/io.h>
|
|
|
|
#include <asm/time.h>
|
|
|
|
|
2006-05-15 10:59:34 -07:00
|
|
|
extern void qemu_reboot_setup(void);
|
|
|
|
|
2005-09-03 15:56:11 -07:00
|
|
|
#define QEMU_PORT_BASE 0xb4000000
|
|
|
|
|
2005-08-15 04:24:34 -07:00
|
|
|
const char *get_system_type(void)
|
|
|
|
{
|
|
|
|
return "Qemu";
|
|
|
|
}
|
|
|
|
|
2006-07-09 13:38:56 -07:00
|
|
|
void __init plat_timer_setup(struct irqaction *irq)
|
2005-09-03 15:56:11 -07:00
|
|
|
{
|
|
|
|
/* set the clock to 100 Hz */
|
|
|
|
outb_p(0x34,0x43); /* binary, mode 2, LSB/MSB, ch 0 */
|
|
|
|
outb_p(LATCH & 0xff , 0x40); /* LSB */
|
|
|
|
outb(LATCH >> 8 , 0x40); /* MSB */
|
|
|
|
setup_irq(0, irq);
|
|
|
|
}
|
|
|
|
|
2006-06-17 17:32:22 -07:00
|
|
|
void __init plat_mem_setup(void)
|
2005-09-03 15:56:11 -07:00
|
|
|
{
|
|
|
|
set_io_port_base(QEMU_PORT_BASE);
|
2006-05-15 10:59:34 -07:00
|
|
|
qemu_reboot_setup();
|
2005-09-03 15:56:11 -07:00
|
|
|
}
|