lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y702hDZk3veZzt+b@unreal>
Date:   Tue, 10 Jan 2023 11:57:24 +0200
From:   Leon Romanovsky <leon@...nel.org>
To:     Hariprasad Kelam <hkelam@...vell.com>
Cc:     netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
        kuba@...nel.org, davem@...emloft.net, pabeni@...hat.com,
        edumazet@...gle.com, sgoutham@...vell.com, gakula@...vell.com,
        sbhatta@...vell.com
Subject: Re: [net PATCH] octeontx2-pf: Fix resource leakage in VF driver
 unbind

On Mon, Jan 09, 2023 at 11:43:25AM +0530, Hariprasad Kelam wrote:
> resources allocated like mcam entries to support the Ntuple feature
> and hash tables for the tc feature are not getting freed in driver
> unbind. This patch fixes the issue.

It is not clear where in otx2vf_probe() these resource are allocated.
Please add the stack trace to the commit message.

Thanks

> 
> Fixes: 2da489432747 ("octeontx2-pf: devlink params support to set mcam entry count")
> Signed-off-by: Hariprasad Kelam <hkelam@...vell.com>
> Signed-off-by: Sunil Kovvuri Goutham <sgoutham@...vell.com>
> ---
>  drivers/net/ethernet/marvell/octeontx2/nic/otx2_vf.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_vf.c b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_vf.c
> index 86653bb8e403..7f8ffbf79cf7 100644
> --- a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_vf.c
> +++ b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_vf.c
> @@ -758,6 +758,8 @@ static void otx2vf_remove(struct pci_dev *pdev)
>  	if (vf->otx2_wq)
>  		destroy_workqueue(vf->otx2_wq);
>  	otx2_ptp_destroy(vf);
> +	otx2_mcam_flow_del(vf);
> +	otx2_shutdown_tc(vf);
>  	otx2vf_disable_mbox_intr(vf);
>  	otx2_detach_resources(&vf->mbox);
>  	if (test_bit(CN10K_LMTST, &vf->hw.cap_flag))
> -- 
> 2.17.1
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ