hw/ppc/ppc405_uc: Drop use of ppcuic_init()
commit71c3c44bc3e4b516efc868b05237aabefbf20fa8
authorPeter Maydell <peter.maydell@linaro.org>
Fri, 8 Jan 2021 17:12:11 +0000 (8 17:12 +0000)
committerDavid Gibson <david@gibson.dropbear.id.au>
Mon, 18 Jan 2021 23:20:29 +0000 (19 10:20 +1100)
tree27b52888d3f8ace8d681bcd4f876afffc9004dd1
parent37dc4b5f7c5ef7300b3a1e2bc298db9edb0efdc5
hw/ppc/ppc405_uc: Drop use of ppcuic_init()

Switch the ppc405_uc boards to directly creating and configuring the
UIC, rather than doing it via the old ppcuic_init() helper function.

We retain the API feature of ppc405ep_init() where it passes back
something allowing the callers to wire up devices to the UIC if
they need to, even though neither of the callsites currently makes
use of this ability -- instead of passing back the qemu_irq array
we pass back the UIC DeviceState.

This fixes a trivial Coverity-detected memory leak where
we were leaking the array of IRQs returned by ppcuic_init().

Fixes: Coverity CID 1421922
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Message-Id: <20210108171212.16500-4-peter.maydell@linaro.org>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
hw/ppc/ppc405.h
hw/ppc/ppc405_boards.c
hw/ppc/ppc405_uc.c