aboutsummaryrefslogtreecommitdiff
path: root/hw/pl110.c
diff options
context:
space:
mode:
authorpbrook <pbrook@c046a42c-6fe2-441c-8c8c-71466251a162>2006-04-09 01:06:34 +0000
committerpbrook <pbrook@c046a42c-6fe2-441c-8c8c-71466251a162>2006-04-09 01:06:34 +0000
commit95219897ff4e6d0502b920c521fccc612ad913dd (patch)
tree424549557f9c83364ac83feddf0120fee9d2abe9 /hw/pl110.c
parent07435f7462e789a8df4718c9b2fc849b54446319 (diff)
downloadqemu-95219897ff4e6d0502b920c521fccc612ad913dd.zip
qemu-95219897ff4e6d0502b920c521fccc612ad913dd.tar.gz
qemu-95219897ff4e6d0502b920c521fccc612ad913dd.tar.bz2
Allow multiple graphics devices.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1803 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'hw/pl110.c')
-rw-r--r--hw/pl110.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/hw/pl110.c b/hw/pl110.c
index 2506dfd..839f103 100644
--- a/hw/pl110.c
+++ b/hw/pl110.c
@@ -89,7 +89,7 @@ static int pl110_enabled(pl110_state *s)
return (s->cr & PL110_CR_EN) && (s->cr & PL110_CR_PWR);
}
-void pl110_update_display(void *opaque)
+static void pl110_update_display(void *opaque)
{
pl110_state *s = (pl110_state *)opaque;
drawfn* fntable;
@@ -205,7 +205,7 @@ void pl110_update_display(void *opaque)
dpy_update(s->ds, 0, first, s->cols, last - first + 1);
}
-void pl110_invalidate_display(void * opaque)
+static void pl110_invalidate_display(void * opaque)
{
pl110_state *s = (pl110_state *)opaque;
s->invalidate = 1;
@@ -378,7 +378,8 @@ static CPUWriteMemoryFunc *pl110_writefn[] = {
pl110_write
};
-void *pl110_init(DisplayState *ds, uint32_t base, void *pic, int irq)
+void *pl110_init(DisplayState *ds, uint32_t base, void *pic, int irq,
+ int versatile)
{
pl110_state *s;
int iomemtype;
@@ -386,11 +387,13 @@ void *pl110_init(DisplayState *ds, uint32_t base, void *pic, int irq)
s = (pl110_state *)qemu_mallocz(sizeof(pl110_state));
iomemtype = cpu_register_io_memory(0, pl110_readfn,
pl110_writefn, s);
- cpu_register_physical_memory(base, 0x007fffff, iomemtype);
+ cpu_register_physical_memory(base, 0x00000fff, iomemtype);
s->base = base;
s->ds = ds;
s->pic = pic;
s->irq = irq;
+ graphic_console_init(ds, pl110_update_display, pl110_invalidate_display,
+ NULL, s);
/* ??? Save/restore. */
return s;
}