From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH] net/vmxnet3: fix mbuf release on reset/stop Date: Mon, 07 Nov 2016 21:14:53 +0100 Message-ID: <3903659.xK46R3T4LA@xps13> References: <1477503907-11306-1-git-send-email-yongwang@vmware.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev@dpdk.org, stephen@networkplumber.org To: Yong Wang Return-path: Received: from mail-wm0-f53.google.com (mail-wm0-f53.google.com [74.125.82.53]) by dpdk.org (Postfix) with ESMTP id 41BF01DB1 for ; Mon, 7 Nov 2016 21:14:55 +0100 (CET) Received: by mail-wm0-f53.google.com with SMTP id t79so199717530wmt.0 for ; Mon, 07 Nov 2016 12:14:55 -0800 (PST) In-Reply-To: <1477503907-11306-1-git-send-email-yongwang@vmware.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 2016-10-26 10:45, Yong Wang: > During device reset/stop, vmxnet3 releases all mbufs in tx and > rx cmd ring. For rx, we should go over all ring descriptors and > free using rte_pktmbuf_free_seg() instead of rte_pktmbuf_free() > as the metadata of the mbuf might not be properly initialized > (initialization after mempool creation is done in the rx routine) > and the mbuf should always be a single-segment one when populated. > For tx, we can use the existing way as mbuf, if any, will be a > valid one stashed in the eop. > > Fixes: dfaff37fc46d ("vmxnet3: import new vmxnet3 poll mode driver implementation") > Signed-off-by: Yong Wang Applied, thanks