> -----Original Message-----
> From: Intel-wired-lan <[email protected]> On Behalf
> Of [email protected]
> Sent: Wednesday, July 15, 2026 10:26 AM
> To: Nguyen, Anthony L <[email protected]>; Kitszel,
> Przemyslaw <[email protected]>; Jagielski; Jagielski,
> Jedrzej <[email protected]>; intel-wired-
> [email protected]
> Cc: Andrew Lunn <[email protected]>; Mitch Williams
> <[email protected]>; Greg Rose <[email protected]>;
> Sudheer Mogilappagari <[email protected]>;
> [email protected]; Xuanqiang Luo <[email protected]>;
> [email protected]
> Subject: [Intel-wired-lan] [PATCH iwl-net v2 2/2] iavf: fix QoS
> capabilities memory leak
>
> From: Xuanqiang Luo <[email protected]>
>
> Commit 4c1a457cb8b0 ("iavf: add support to exchange qos capabilities")
> allocates adapter->qos_caps during probe, but iavf_remove() does not
> free it. This leaks the allocation whenever an iavf device is removed.
>
> Free adapter->qos_caps in iavf_remove().
>
> Fixes: 4c1a457cb8b0 ("iavf: add support to exchange qos capabilities")
> Cc: [email protected]
> Reviewed-by: Jedrzej Jagielski <[email protected]>
> Signed-off-by: Xuanqiang Luo <[email protected]>
> ---
> drivers/net/ethernet/intel/iavf/iavf_main.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/net/ethernet/intel/iavf/iavf_main.c
> b/drivers/net/ethernet/intel/iavf/iavf_main.c
> index 29b8403a066bc..c7f69a9040588 100644
> --- a/drivers/net/ethernet/intel/iavf/iavf_main.c
> +++ b/drivers/net/ethernet/intel/iavf/iavf_main.c
> @@ -5589,6 +5589,7 @@ static void iavf_remove(struct pci_dev *pdev)
> iounmap(hw->hw_addr);
> pci_release_regions(pdev);
> kfree(adapter->vf_res);
> + kfree(adapter->qos_caps);
> spin_lock_bh(&adapter->mac_vlan_list_lock);
> /* If we got removed before an up/down sequence, we've got a
> filter
> * hanging out there that we need to get rid of.
> --
> 2.43.0
Reviewed-by: Aleksandr Loktionov <[email protected]>