From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ee0-f53.google.com (mail-ee0-f53.google.com [74.125.83.53]) by dpdk.org (Postfix) with ESMTP id 64E54156 for ; Tue, 12 Nov 2013 16:49:02 +0100 (CET) Received: by mail-ee0-f53.google.com with SMTP id e51so3292174eek.12 for ; Tue, 12 Nov 2013 07:49:56 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :cc:subject:references:in-reply-to:content-type :content-transfer-encoding; bh=vxiqquJ3QXeBW5+it/l3d5DsVAPaVCaWGJ8d1gyaxiY=; b=i/PUEDODGk4bR96fGQLxn6wlIGk2ry6FXGQKlGOOTpGvn1imcc0U9LX4kd9D6wjRJm 0BkIFI9aW2+BVJWCJIQ8jno+SAkEX5x41303EaVwjQAUySgkJHgmAKCZxlHPvUnj20JD uRtUIMq7FQ5r0wwxymdDNUdKTxBYfVAeVgDd5/67LaXuGzL2WJrrLeOipdDbvXyQKW1G fBVD/DqJ88Xx8yR4Ir660IeM8dXgJj/LpNmL5aHf0Y2Z6N+TIb/lNdhIbC/IMEzYd7/W xtJJCuuCOEIlIYv1pwUdE5g+04vmIrg1Q4tu6zTgNvZ2IMNj5KyExSpd2plzLGqjLGYA hu4g== X-Gm-Message-State: ALoCoQltfwvZz8KXEEkQV97cSZLmK1j/G1UiGtGfr8S06Fg21WS9PUjOtvC+9qXmtOLhyeIB0qR9 X-Received: by 10.15.94.201 with SMTP id bb49mr42986406eeb.23.1384271396637; Tue, 12 Nov 2013 07:49:56 -0800 (PST) Received: from [10.16.0.189] (6wind.net2.nerim.net. [213.41.180.237]) by mx.google.com with ESMTPSA id l9sm17830377eew.6.2013.11.12.07.49.54 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 12 Nov 2013 07:49:55 -0800 (PST) Message-ID: <52824E21.20405@6wind.com> Date: Tue, 12 Nov 2013 16:49:53 +0100 From: Ivan Boule User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130922 Icedove/17.0.9 MIME-Version: 1.0 To: Bryan Benson References: <1383940042-31770-1-git-send-email-bmbenson@amazon.com> In-Reply-To: <1383940042-31770-1-git-send-email-bmbenson@amazon.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org Subject: Re: [dpdk-dev] [PATCH] ixgbe: Fix offloading bits when RX bulk alloc is used. X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Nov 2013 15:49:02 -0000 On 11/08/2013 08:47 PM, Bryan Benson wrote: > This is a fix for the ixgbe hardware offload flags not being set when bulk alloc RX is used. The issue was caused by masking off the bits that store the hardware offload values in the status_error field to retrieve the done bit for the descriptor. > > Commit 7431041062b9fd0555bac7ca4abebc99e3379fa5 in DPDK-1.3.0 introduced bulk dequeue, which included the bug. > --- > lib/librte_pmd_ixgbe/ixgbe_rxtx.c | 13 +++++++------ > 1 file changed, 7 insertions(+), 6 deletions(-) > > diff --git a/lib/librte_pmd_ixgbe/ixgbe_rxtx.c b/lib/librte_pmd_ixgbe/ixgbe_rxtx.c > index 07830b7..a183c11 100755 > --- a/lib/librte_pmd_ixgbe/ixgbe_rxtx.c > +++ b/lib/librte_pmd_ixgbe/ixgbe_rxtx.c > @@ -1035,7 +1035,8 @@ ixgbe_rx_scan_hw_ring(struct igb_rx_queue *rxq) > struct igb_rx_entry *rxep; > struct rte_mbuf *mb; > uint16_t pkt_len; > - int s[LOOK_AHEAD], nb_dd; > + uint32_t s[LOOK_AHEAD]; > + int nb_dd; > int i, j, nb_rx = 0; > > > @@ -1058,12 +1059,12 @@ ixgbe_rx_scan_hw_ring(struct igb_rx_queue *rxq) > for (j = LOOK_AHEAD-1; j >= 0; --j) > s[j] = rxdp[j].wb.upper.status_error; > > - /* Clear everything but the status bits (LSB) */ > - for (j = 0; j < LOOK_AHEAD; ++j) > - s[j] &= IXGBE_RXDADV_STAT_DD; > + nb_dd = 0; > + /* add to nd_dd when the status bit is set (LSB) */ > + for (j = 0; j < LOOK_AHEAD; ++j) { > + nb_dd += s[j] & IXGBE_RXDADV_STAT_DD; > + } > > - /* Compute how many status bits were set */ > - nb_dd = s[0]+s[1]+s[2]+s[3]+s[4]+s[5]+s[6]+s[7]; > nb_rx += nb_dd; > > /* Translate descriptor info to mbuf format */ Acked. -- Ivan Boule 6WIND Development Engineer