diff options
author | Peter Crosthwaite <peter.crosthwaite@xilinx.com> | 2014-06-18 00:56:31 -0700 |
---|---|---|
committer | Andreas Färber <afaerber@suse.de> | 2014-07-01 04:02:53 +0200 |
commit | f173d57a4cd3bb2a8362fe376cd9fd776b2f57d5 (patch) | |
tree | f4b392449f53293e948ec32edbbfc01865bb78ca /hw/ipack | |
parent | f3c7d0389fe8a2792fd4c1cf151b885de03c8f62 (diff) |
irq: Allocate IRQs individually
Allocate each IRQ individually on array allocations. This prepares for
QOMification of IRQs, where pointers to individual IRQs may be taken
and handed around for usage as QOM Links. The g_renew() scheme used here
is too fragile and would break all existing links should an IRQ list
be extended.
We now have to pass the IRQ count to qemu_free_irqs(). We have so few
call sites however, so this change is reasonably trivial.
Cc: agarcia@igalia.com
Cc: mst@redhat.com
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Acked-by: Alberto Garcia <agarcia@igalia.com>
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'hw/ipack')
-rw-r--r-- | hw/ipack/ipack.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/ipack/ipack.c b/hw/ipack/ipack.c index ef032e6604..59bfe2869e 100644 --- a/hw/ipack/ipack.c +++ b/hw/ipack/ipack.c @@ -66,7 +66,7 @@ static void ipack_device_unrealize(DeviceState *dev, Error **errp) return; } - qemu_free_irqs(idev->irq); + qemu_free_irqs(idev->irq, 2); } static Property ipack_device_props[] = { |