From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lf0-f46.google.com (mail-lf0-f46.google.com [209.85.215.46]) by dpdk.org (Postfix) with ESMTP id CE5022949 for ; Mon, 18 Apr 2016 18:01:03 +0200 (CEST) Received: by mail-lf0-f46.google.com with SMTP id e190so222474372lfe.0 for ; Mon, 18 Apr 2016 09:01:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc; bh=RphfpeW5u8xpcHdEE8tEREmbVasGHU32Cjq+vP5wpwo=; b=f/NgjaM/IBdYybM1l+M/tQ6C4m4XyK+zQiWgGpF7UhweAzNWWTeIJW4TitsgD10oGe zS1hVELIDfHchhnSYyvcPrMRoOhci8FjGVlhD65Q8szt07b7MXEZ2SGdBkmJ4RzN/9Cr ieDTqXaiA93x4JTee6Dj43RPbASB3oAV+K7v2y3zaaEPa23Vs7VFnLsFl0H1R8M1dwli xSmq8Eiam9w4Qnom+BlLABWn9yhC2b5rhSai+lE5Fg9HXJJciOM+/pD+1eSsuEw1yg0Q WliDLLG/SDMjyBrxZGSLO8GSlYuurPYhLEs4OHxCGyiwft/eADKXVnFehsvFvReFK2qE vyZg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc; bh=RphfpeW5u8xpcHdEE8tEREmbVasGHU32Cjq+vP5wpwo=; b=Bk9/m66jpOXDKmLpgvXzxnzOqqrXMaEzelevaGm8vN2H4Zb7DLrOaps9wawMZNyL2Y qWu4z9BGtpkKqs5ZbYysI0VBOQ1ZKrdgQQY5sri51ZwQl96DVnZWe/eNktQIIZ72PdUA iTYtdqRTKW9wYaYzZzyNNnkx4ykmBuj7JHUEoDcGmvixjZwtBQldKteSrEJpSTUOIEOg XkZdOEQS5xyyAMJTSTWsKY0O6Zi39ZZ3I3E5k2tLV6recvkrIcMPgXYcb9wkWqLu/7hJ HXIF26M2FLYvxuNVPcgF/AJ1pfGkyoJHUj1U18RQwc5mn8S8cnuxvg2rrPytvyyFDz1A Mn2Q== X-Gm-Message-State: AOPr4FX/dkYfNKLt5rQYCMH3bt8Q6P0ORKHYGz8NFeO3c2VYlEghmkfwH/wmwzF03XmfLkRawoxLyTY3z/5h1g== MIME-Version: 1.0 X-Received: by 10.25.213.210 with SMTP id m201mr15709337lfg.116.1460995263537; Mon, 18 Apr 2016 09:01:03 -0700 (PDT) Received: by 10.112.164.40 with HTTP; Mon, 18 Apr 2016 09:01:03 -0700 (PDT) In-Reply-To: References: Date: Mon, 18 Apr 2016 18:01:03 +0200 Message-ID: From: =?UTF-8?Q?Javier_Coleto_Fern=C3=A1ndez?= To: Andriy Berestovskyy Cc: "Wiles, Keith" , users Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-users] mbuf free cnt not decreasing X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Apr 2016 16:01:04 -0000 This is exactly what I'm doing at the moment, but the free count (both the rte_mempool_free_count() and rte_ring_free_count()) keeps increasing nonetheless. Regards, Javier 2016-04-18 17:57 GMT+02:00 Andriy Berestovskyy : > On Mon, Apr 18, 2016 at 5:34 PM, Javier Coleto Fern=C3=A1ndez > wrote: > > Basing on what you say, is that return value supposed to be less than > 'n' in > > case the ring is filled up or do I have to check the ring size before > > calling rte_eth_tx_burst()? > > You just have to check the return value and free the unsent mbufs. > Here is an example: > > ret =3D rte_eth_tx_burst(port, queueid, m_table, n); > if (unlikely(ret < n)) { > do { > rte_pktmbuf_free(m_table[ret]); > } while (++ret < n); > } > > > Regards, > Andiry >