hw/ide/macio: switch from using qemu_allocate_irq() to qdev input GPIOs

This prevents the IRQs from being leaked when the macio IDE device is used.

Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Akihiko Odaki <akihiko.odaki@daynix.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20240628160334.653168-1-mark.cave-ayland@ilande.co.uk>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
This commit is contained in:
Mark Cave-Ayland 2024-06-28 17:03:34 +01:00 committed by Philippe Mathieu-Daudé
parent 0ff3243a46
commit efb359346c
2 changed files with 11 additions and 6 deletions

View file

@ -80,8 +80,6 @@ struct MACIOIDEState {
uint32_t channel;
qemu_irq real_ide_irq;
qemu_irq real_dma_irq;
qemu_irq ide_irq;
qemu_irq dma_irq;
MemoryRegion mem;
IDEBus bus;
@ -92,6 +90,11 @@ struct MACIOIDEState {
uint32_t irq_reg;
};
#define MACIO_IDE_PMAC_NIRQS 2
#define MACIO_IDE_PMAC_DMA_IRQ 0
#define MACIO_IDE_PMAC_IDE_IRQ 1
void macio_ide_init_drives(MACIOIDEState *ide, DriveInfo **hd_table);
void macio_ide_register_dma(MACIOIDEState *ide);