diff options
author | Gerd Hoffmann <kraxel@redhat.com> | 2009-09-10 11:43:27 +0200 |
---|---|---|
committer | malc <av1474@comtv.ru> | 2009-09-10 19:47:59 +0400 |
commit | 2e15e23b8a3c5da5576b7ea8631c956381eea0d5 (patch) | |
tree | 6b58c916a271c2fa707f39210a71094a4cfafe06 /hw/fdc.c | |
parent | 86c861578453b544fa67ad50d28c4460bee068c5 (diff) |
qdev: simplify isa irq assignments
isa-bus owns the isa irqs now, so it can hand them out directly.
There is no need for the separate isa_connect_irqs step, drop it.
Also hard-code isa interrupts which can't be configured anyway.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'hw/fdc.c')
-rw-r--r-- | hw/fdc.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -1875,10 +1875,9 @@ fdctrl_t *fdctrl_init_isa(BlockDriverState **fds) { fdctrl_t *fdctrl; ISADevice *dev; - int isairq = 6; int dma_chann = 2; - dev = isa_create_simple("isa-fdc", isairq, -1); + dev = isa_create_simple("isa-fdc"); fdctrl = &(DO_UPCAST(fdctrl_isabus_t, busdev, dev)->state); fdctrl->dma_chann = dma_chann; @@ -1969,6 +1968,7 @@ static int isabus_fdc_init1(ISADevice *dev) fdctrl_isabus_t *isa = DO_UPCAST(fdctrl_isabus_t, busdev, dev); fdctrl_t *fdctrl = &isa->state; int iobase = 0x3f0; + int isairq = 6; register_ioport_read(iobase + 0x01, 5, 1, &fdctrl_read_port, fdctrl); @@ -1978,7 +1978,7 @@ static int isabus_fdc_init1(ISADevice *dev) &fdctrl_write_port, fdctrl); register_ioport_write(iobase + 0x07, 1, 1, &fdctrl_write_port, fdctrl); - isa_init_irq(&isa->busdev, &fdctrl->irq); + isa_init_irq(&isa->busdev, &fdctrl->irq, isairq); return fdctrl_init_common(fdctrl); } |