[PATCH 8/8] net/ice: fix DCF port leak on probe failure

Bruce Richardson bruce.richardson at intel.com
Fri Nov 6 13:18:37 CET 2026


On Thu, Nov 05, 2026 at 09:47:25AM +0000, Anurag Mandal wrote:
> When representors are requested, eth_ice_dcf_pci_probe() creates
> the DCF port before handling them.
> If a later step fails, such as an unsupported representor type,
> an invalid VF ID or a failed representor creation, the probe
> returns an error but leaves the DCF port and any representors
> already created in place.
> As the probe failed, the PCI bus also unmaps the device, so
> these ports are leaked and cannot be closed safely.
> 
> Check the representor type before creating the DCF port, and
> on later failures destroy the representors created so far and
> remove the DCF port.
> 
> Fixes: 5674465a32c8 ("net/ice: add DCF VLAN handling")
> Fixes: d654167641bf ("ethdev: introduce representor type")
> Cc: stable at dpdk.org
> 
> Signed-off-by: Anurag Mandal <anurag.mandal at intel.com>
> ---
>  drivers/net/intel/ice/ice_dcf_ethdev.c | 25 ++++++++++++++++++++-----
>  1 file changed, 20 insertions(+), 5 deletions(-)
> 
Acked-by: Bruce Richardson <bruce.richardson at intel.com>


More information about the stable mailing list