patch 'net/bnxt: fix memory leak in VF VNIC query error path' has been queued to stable release 25.11.5
Kishore Padmanabha
kishore.padmanabha at broadcom.com
Thu Dec 3 15:52:20 CET 2026
Please go ahead with the merge.
Thanks,
Kishore
On Thu, Dec 3, 2026 at 8:12 AM Kevin Traynor <ktraynor at redhat.com> wrote:
> Hi,
>
> FYI, your patch has been queued to stable release 25.11.5
>
> Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
> It will be pushed if I get no objections before 12/08/26. So please
> shout if anyone has objections.
>
> Also note that after the patch there's a diff of the upstream commit vs the
> patch applied to the branch. This will indicate if there was any rebasing
> needed to apply to the stable branch. If there were code changes for
> rebasing
> (ie: not only metadata diffs), please double check that the rebase was
> correctly done.
>
> Queued patches are on a temporary branch at:
> https://github.com/kevintraynor/dpdk-stable
>
> This queued commit can be viewed at:
>
> https://github.com/kevintraynor/dpdk-stable/commit/82e7a9391e51ed4da2fb762a7d8c707930fd65ab
>
> Thanks.
>
> Kevin
>
> ---
> From 82e7a9391e51ed4da2fb762a7d8c707930fd65ab Mon Sep 17 00:00:00 2001
> From: Kishore Padmanabha <kishore.padmanabha at broadcom.com>
> Date: Tue, 29 Sep 2026 12:04:18 -0600
> Subject: [PATCH] net/bnxt: fix memory leak in VF VNIC query error path
>
> [ upstream commit 374a9e57a59c847aede1d68474ac90787e3b2922 ]
>
> bnxt_hwrm_func_vf_vnic_query_and_config() allocates vnic_ids before
> calling bnxt_hwrm_func_vf_vnic_query(), but returns without freeing it
> when that call fails.
>
> Free vnic_ids on the error path too.
>
> Fixes: 49947a13ba9e ("net/bnxt: support Tx loopback, set VF MAC and queues
> drop")
>
> Signed-off-by: Kishore Padmanabha <kishore.padmanabha at broadcom.com>
> Signed-off-by: Mohammad Shuab Siddique <
> mohammad-shuab.siddique at broadcom.com>
> ---
> drivers/net/bnxt/bnxt_hwrm.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/net/bnxt/bnxt_hwrm.c b/drivers/net/bnxt/bnxt_hwrm.c
> index 6e02eab086..4ed4997afa 100644
> --- a/drivers/net/bnxt/bnxt_hwrm.c
> +++ b/drivers/net/bnxt/bnxt_hwrm.c
> @@ -6238,6 +6238,8 @@ int bnxt_hwrm_func_vf_vnic_query_and_config(struct
> bnxt *bp, uint16_t vf,
> num_vnic_ids = bnxt_hwrm_func_vf_vnic_query(bp, vf, vnic_ids);
>
> - if (num_vnic_ids < 0)
> + if (num_vnic_ids < 0) {
> + rte_free(vnic_ids);
> return num_vnic_ids;
> + }
>
> /* Retrieve VNIC, update bd_stall then update */
> --
> 2.56.1
>
> ---
> Diff of the applied patch vs upstream commit (please double-check if
> non-empty:
> ---
> --- - 2026-12-03 12:52:44.868685252 +0000
> +++ 0197-net-bnxt-fix-memory-leak-in-VF-VNIC-query-error-path.patch
> 2026-12-03 12:52:39.174938690 +0000
> @@ -1 +1 @@
> -From 374a9e57a59c847aede1d68474ac90787e3b2922 Mon Sep 17 00:00:00 2001
> +From 82e7a9391e51ed4da2fb762a7d8c707930fd65ab Mon Sep 17 00:00:00 2001
> @@ -5,0 +6,2 @@
> +[ upstream commit 374a9e57a59c847aede1d68474ac90787e3b2922 ]
> +
> @@ -13 +14,0 @@
> -Cc: stable at dpdk.org
> @@ -22 +23 @@
> -index d533965217..29b18a5cf1 100644
> +index 6e02eab086..4ed4997afa 100644
> @@ -25 +26 @@
> -@@ -6279,6 +6279,8 @@ int bnxt_hwrm_func_vf_vnic_query_and_config(struct
> bnxt *bp, uint16_t vf,
> +@@ -6238,6 +6238,8 @@ int bnxt_hwrm_func_vf_vnic_query_and_config(struct
> bnxt *bp, uint16_t vf,
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mails.dpdk.org/archives/stable/attachments/20261203/3fc05078/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5493 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://mails.dpdk.org/archives/stable/attachments/20261203/3fc05078/attachment.bin>
More information about the stable
mailing list