From: Mark Zhang <markzhang@nvidia.com>
To: YueHaibing <yuehaibing@huawei.com>,
borisp@nvidia.com, saeedm@nvidia.com, leon@kernel.org,
davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
pabeni@redhat.com, lkayal@nvidia.com, tariqt@nvidia.com
Cc: netdev@vger.kernel.org, linux-rdma@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] net/mlx5e: Use kvfree() in mlx5e_accel_fs_tcp_create()
Date: Tue, 8 Nov 2022 21:16:12 +0800 [thread overview]
Message-ID: <937e019a-f911-8fcb-6f0f-d23188ced89c@nvidia.com> (raw)
In-Reply-To: <20221108130411.6932-1-yuehaibing@huawei.com>
On 11/8/2022 9:04 PM, YueHaibing wrote:
> 'accel_tcp' is allocated by kzalloc(), which should freed by kvfree().
'accel_tcp' is allocated by kvzalloc()
>
> Fixes: f52f2faee581 ("net/mlx5e: Introduce flow steering API")
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
> ---
> drivers/net/ethernet/mellanox/mlx5/core/en_accel/fs_tcp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/fs_tcp.c b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/fs_tcp.c
> index 285d32d2fd08..7843c60d5b99 100644
> --- a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/fs_tcp.c
> +++ b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/fs_tcp.c
> @@ -397,7 +397,7 @@ int mlx5e_accel_fs_tcp_create(struct mlx5e_flow_steering *fs)
> err_destroy_tables:
> while (--i >= 0)
> accel_fs_tcp_destroy_table(fs, i);
> - kfree(accel_tcp);
> + kvfree(accel_tcp);
> mlx5e_fs_set_accel_tcp(fs, NULL);
> return err;
> }
Need to fix mlx5e_accel_fs_tcp_destroy() as well?
next prev parent reply other threads:[~2022-11-08 13:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-08 13:04 YueHaibing
2022-11-08 13:16 ` Mark Zhang [this message]
2022-11-08 13:52 ` YueHaibing
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=937e019a-f911-8fcb-6f0f-d23188ced89c@nvidia.com \
--to=markzhang@nvidia.com \
--cc=borisp@nvidia.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=leon@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=lkayal@nvidia.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=saeedm@nvidia.com \
--cc=tariqt@nvidia.com \
--cc=yuehaibing@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®