]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: arm64: vgic-its: Fix memory leak on the error path of vgic_add_lpi()
authorZenghui Yu <yuzenghui@huawei.com>
Tue, 14 Apr 2020 03:03:48 +0000 (11:03 +0800)
committerMarc Zyngier <maz@kernel.org>
Thu, 23 Apr 2020 15:26:56 +0000 (16:26 +0100)
commitcc2891291eaf72ed2c8660c524d8cd1ce08ee155
treec3ef73b2a34540ec32b1195025b0f8a5d18ed4d3
parenta1154d87742db6be2e1fc62681166f6b07dada8a
KVM: arm64: vgic-its: Fix memory leak on the error path of vgic_add_lpi()

If we're going to fail out the vgic_add_lpi(), let's make sure the
allocated vgic_irq memory is also freed. Though it seems that both
cases are unlikely to fail.

Signed-off-by: Zenghui Yu <yuzenghui@huawei.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20200414030349.625-3-yuzenghui@huawei.com
virt/kvm/arm/vgic/vgic-its.c