[dpdk-stable] [dpdk-dev] [PATCH] net/i40e: fix unexpected mbuf free in vPMD
bruce.richardson at intel.com
Mon Oct 9 15:20:58 CEST 2017
On Mon, Oct 09, 2017 at 12:44:25PM +0000, Ananyev, Konstantin wrote:
> Hi Zhang,
> > -----Original Message-----
> > From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Qi Zhang
> > Sent: Monday, October 9, 2017 9:54 AM
> > To: Wu, Jingjing <jingjing.wu at intel.com>; Xing, Beilei <beilei.xing at intel.com>
> > Cc: dev at dpdk.org; Zhang, Qi Z <qi.z.zhang at intel.com>; stable at dpdk.org
> > Subject: [dpdk-dev] [PATCH] net/i40e: fix unexpected mbuf free in vPMD
> > The patch reset tx queue sw_ring's mbuf to NULL after it is free in
> > i40_tx_free_bufs, this prevent same mbuf be free again in
> > i40e_dev_tx_queue_release. This fix follow the same implemenation of
> > non-vPMD.
> Wonder why we can't change i40e_dev_tx_queue_release() instead,
> so it will only go through the TXDs that were really armed?
> Let say from txq->tx_next_dd - tx_rs_thresh - 1 till txq->tx_tail?
> Let say _ixgbe_tx_queue_release_mbufs_vec() works that way.
> Then we probably can keep our runtime code intact.
+1 to this. We should avoid adding writes to the TX path. Instead we
should ensure that other routines properly track the buffers to be freed
using the appropriate indexes.
More information about the stable