aboutsummaryrefslogtreecommitdiff
path: root/hw/intc
diff options
context:
space:
mode:
authorMark Cave-Ayland <mark.cave-ayland@ilande.co.uk>2018-03-06 22:01:54 +0000
committerDavid Gibson <david@gibson.dropbear.id.au>2018-04-27 18:05:22 +1000
commita5ed75fe2e6625b2ab9ed0694d7a5c95a74b84f7 (patch)
tree7c302108a86584a0fea3ebf4a3c4d910e57a1fdd /hw/intc
parent0f4b5415c31ed1fee02f5826fe0d2d585806fa95 (diff)
heathrow: remove obsolete heathow_init() function
Instead wire up heathrow to the CPU and grackle PCI host using qdev GPIOs. Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'hw/intc')
-rw-r--r--hw/intc/heathrow_pic.c23
1 files changed, 5 insertions, 18 deletions
diff --git a/hw/intc/heathrow_pic.c b/hw/intc/heathrow_pic.c
index 393fdd7326..b8b997deca 100644
--- a/hw/intc/heathrow_pic.c
+++ b/hw/intc/heathrow_pic.c
@@ -172,27 +172,14 @@ static void heathrow_init(Object *obj)
HeathrowState *s = HEATHROW(obj);
SysBusDevice *sbd = SYS_BUS_DEVICE(obj);
- memory_region_init_io(&s->mem, OBJECT(s), &heathrow_ops, s,
- "heathrow-pic", 0x1000);
- sysbus_init_mmio(sbd, &s->mem);
-}
-
-DeviceState *heathrow_pic_init(int nb_cpus, qemu_irq **irqs,
- qemu_irq **pic_irqs)
-{
- DeviceState *d;
- HeathrowState *s;
-
- d = qdev_create(NULL, TYPE_HEATHROW);
- qdev_init_nofail(d);
-
- s = HEATHROW(d);
/* only 1 CPU */
- s->irqs = irqs[0];
+ qdev_init_gpio_out(DEVICE(obj), s->irqs, 1);
- *pic_irqs = qemu_allocate_irqs(heathrow_set_irq, s, HEATHROW_NUM_IRQS);
+ qdev_init_gpio_in(DEVICE(obj), heathrow_set_irq, HEATHROW_NUM_IRQS);
- return d;
+ memory_region_init_io(&s->mem, OBJECT(s), &heathrow_ops, s,
+ "heathrow-pic", 0x1000);
+ sysbus_init_mmio(sbd, &s->mem);
}
static void heathrow_class_init(ObjectClass *oc, void *data)