[PATCH v2 1/2] net/i40e: fix return value of close operation

Bruce Richardson bruce.richardson at intel.com
Thu Jul 23 12:53:54 CEST 2026


On Thu, Jul 23, 2026 at 11:32:20AM +0100, Bruce Richardson wrote:
> On Wed, Jul 15, 2026 at 02:48:15PM +0200, Sid Ali Cherrati wrote:
> > rte_intr_callback_unregister() returns the number of unregistered
> > callbacks on success. Since the close operation started returning
> > the ret variable instead of 0, this positive value leaks as the
> > return value of i40e_dev_close(), so applications checking
> > rte_eth_dev_close() != 0 treat a successful close as a failure.
> > 
> > Use a separate cb_ret variable for the unregister return value so a
> > successful unregister never clobbers an earlier error stored in ret,
> > and stop retrying once unregister fails with anything other than
> > -EAGAIN, since those errors are not transient.
> > 
> > Fixes: 62024eb82756 ("ethdev: change stop operation callback to return int")
> > Cc: stable at dpdk.org
> > 
> > Signed-off-by: Sid Ali Cherrati <scherrati1 at gmail.com>
> Acked-by: Bruce Richardson <bruce.richardson at intel.com>
> > ---

Both patches applied to dpdk-next-net-intel.

Thanks,
/Bruce


More information about the dev mailing list