hw/ufs: free irq on exit
PATCH 1/1 hw/ufs: free irq on exit
Hi,
This patch fixes a memory leak bug in ufs_init_pci(). u->irq is not freed in ufs_exit().
Signed-off-by Zheng Huang <[email protected]>
--- hw/ufs/ufs.c | 3 +++ 1 file changed, 3 insertions(+)
hw/ufs/ufs.c +3 -0
@@ -25,6 +25,7 @@#include "qapi/error.h" #include "migration/vmstate.h" #include "scsi/constants.h" +#include "hw/irq.h" #include "trace.h" #include "ufs.h"
@@ -1732,6 +1733,8 @@ static void ufs_exit(PCIDevice *pci_dev) {UfsHc *u =UFS (pci_dev); +qemu_free_irq (u->irq); +qemu_bh_delete (u->doorbell_bh);qemu_bh_delete (u->complete_bh);
Signature · 1 line
2.34.1
Quoted 10 lines · Zheng Huang
Hi,
This patch fixes a memory leak bug in
ufs_init_pci().u->irqis not freed inufs_exit().Signed-off-by Zheng Huang <[email protected]>--- hw/ufs/ufs.c | 3 +++ 1 file changed, 3 insertions(+)
Reviewed-by Philippe Mathieu-Daudé <[email protected]>
Philippe Mathieu-Daudé
AppliedQuoted 10 lines · Zheng Huang
Hi,
This patch fixes a memory leak bug in
ufs_init_pci().u->irqis not freed inufs_exit().Signed-off-by Zheng Huang <[email protected]>--- hw/ufs/ufs.c | 3 +++ 1 file changed, 3 insertions(+)
Queued to hw-misc, thanks!