On 12/12/20 3:41 PM, Peter Maydell wrote: > Currently the GRLIB_IRQMP device is used in one place (the leon3 board), > but instead of the device providing inbound gpio lines for the board > to wire up, the board code itself calls qemu_allocate_irqs() with > the handler function being a set_irq function defined in the code > for the device. > > Refactor this into the standard setup of a device having input > gpio lines. > > This fixes a trivial Coverity memory leak report (the leon3 > board code leaks the IRQ array returned from qemu_allocate_irqs()). > > Fixes: Coverity CID 1421922 > Signed-off-by: Peter Maydell <peter.mayd...@linaro.org> > --- > include/hw/sparc/grlib.h | 2 -- > hw/intc/grlib_irqmp.c | 5 ++++- > hw/sparc/leon3.c | 21 +++++++++------------ > 3 files changed, 13 insertions(+), 15 deletions(-)
Reviewed-by: Philippe Mathieu-Daudé <f4...@amsat.org>