mirror of
https://github.com/torvalds/linux.git
synced 2026-05-31 18:43:33 +02:00
net: mana: Fix memory leak in mana_gd_setup_irqs
Commit8afefc3612("net: mana: Assigning IRQ affinity on HT cores") added memory allocation in mana_gd_setup_irqs of 'irqs' but the code doesn't free this temporary array in the success path. This was caught by kmemleak. Fixes:8afefc3612("net: mana: Assigning IRQ affinity on HT cores") Signed-off-by: Maxim Levitsky <mlevitsk@redhat.com> Reviewed-by: Michal Swiatkowski <michal.swiatkowski@linux.intel.com> Reviewed-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com> Reviewed-by: Saurabh Sengar <ssengar@linux.microsoft.com> Reviewed-by: Yury Norov <yury.norov@gmail.com> Link: https://patch.msgid.link/20241209175751.287738-2-mlevitsk@redhat.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
15bfb14727
commit
bb1e3eb57d
|
|
@ -1375,6 +1375,7 @@ static int mana_gd_setup_irqs(struct pci_dev *pdev)
|
|||
gc->max_num_msix = nvec;
|
||||
gc->num_msix_usable = nvec;
|
||||
cpus_read_unlock();
|
||||
kfree(irqs);
|
||||
return 0;
|
||||
|
||||
free_irq:
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user