patch 'net/ice: fix PHY capabilities buffer leak' has been queued to stable release 24.11.9

luca.boccassi at gmail.com luca.boccassi at gmail.com
Tue Oct 27 12:50:48 CET 2026


Hi,

FYI, your patch has been queued to stable release 24.11.9

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 10/29/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/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/926a7f43045e8dd59d8218720fb1581fe7b62d0c

Thanks.

Luca Boccassi

---
>From 926a7f43045e8dd59d8218720fb1581fe7b62d0c Mon Sep 17 00:00:00 2001
From: Anurag Mandal <anurag.mandal at intel.com>
Date: Wed, 30 Sep 2026 16:52:30 +0000
Subject: [PATCH] net/ice: fix PHY capabilities buffer leak

[ upstream commit 3779580c5c80b6e5fedff4b2185e377871cba63a ]

ice_phy_conf_link() allocates the PHY capabilities buffer and only then
validates hw->port_info.  If hw->port_info is NULL,it returns directly
without freeing PHY capabilities buffer causing the buffer leak.

Fix the issue by moving the hw->port_info NULL check above the PHY
capabilities buffer allocation.

Fixes: 36afbc269081 ("net/ice: support link speed change")

Signed-off-by: Anurag Mandal <anurag.mandal at intel.com>
Acked-by: Anatoly Burakov <anatoly.burakov at intel.com>
---
 drivers/net/ice/ice_ethdev.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ice/ice_ethdev.c b/drivers/net/ice/ice_ethdev.c
index f0d85f36bfa..0c4036dbad9 100644
--- a/drivers/net/ice/ice_ethdev.c
+++ b/drivers/net/ice/ice_ethdev.c
@@ -4430,14 +4430,14 @@ ice_phy_conf_link(struct ice_hw *hw,
 	u64 phy_type_low = 0;
 	u64 phy_type_high = 0;
 
+	if (!pi)
+		return -EIO;
+
 	phy_caps = (struct ice_aqc_get_phy_caps_data *)
 		ice_malloc(hw, sizeof(*phy_caps));
 	if (!phy_caps)
 		return ICE_ERR_NO_MEMORY;
 
-	if (!pi)
-		return -EIO;
-
 
 	if (ice_fw_supports_report_dflt_cfg(pi->hw))
 		err = ice_aq_get_phy_caps(pi, false, ICE_AQC_REPORT_DFLT_CFG,
-- 
2.47.3

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2026-10-27 11:43:59.633441609 +0000
+++ 0154-net-ice-fix-PHY-capabilities-buffer-leak.patch	2026-10-27 11:43:53.702065268 +0000
@@ -1 +1 @@
-From 3779580c5c80b6e5fedff4b2185e377871cba63a Mon Sep 17 00:00:00 2001
+From 926a7f43045e8dd59d8218720fb1581fe7b62d0c Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 3779580c5c80b6e5fedff4b2185e377871cba63a ]
+
@@ -14 +15,0 @@
-Cc: stable at dpdk.org
@@ -19 +20 @@
- drivers/net/intel/ice/ice_ethdev.c | 6 +++---
+ drivers/net/ice/ice_ethdev.c | 6 +++---
@@ -22,5 +23,5 @@
-diff --git a/drivers/net/intel/ice/ice_ethdev.c b/drivers/net/intel/ice/ice_ethdev.c
-index 163304ba1e..5f252a2ce0 100644
---- a/drivers/net/intel/ice/ice_ethdev.c
-+++ b/drivers/net/intel/ice/ice_ethdev.c
-@@ -5253,14 +5253,14 @@ ice_phy_conf_link(struct ice_hw *hw,
+diff --git a/drivers/net/ice/ice_ethdev.c b/drivers/net/ice/ice_ethdev.c
+index f0d85f36bfa..0c4036dbad9 100644
+--- a/drivers/net/ice/ice_ethdev.c
++++ b/drivers/net/ice/ice_ethdev.c
+@@ -4430,14 +4430,14 @@ ice_phy_conf_link(struct ice_hw *hw,


More information about the stable mailing list