From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wi0-f178.google.com (mail-wi0-f178.google.com [209.85.212.178]) by dpdk.org (Postfix) with ESMTP id 72AD08D3D for ; Tue, 27 Oct 2015 18:40:18 +0100 (CET) Received: by wicll6 with SMTP id ll6so171324355wic.1 for ; Tue, 27 Oct 2015 10:40:18 -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:content-type; bh=T95YwIrPwZO8FZCTXd622wBIfHdRQPfZi/MM5Nhf4rk=; b=Bz8LScn0ALvGOEwPObb1rVKIH8goN4ui0DaMnAZn+SbZGGCMcui2vU82/myQYLQjvA cX3jUBe7w5LeS1m0av2Nop/1kOx9xd2vlsJnFkTkOYgC7h0hoO+DLqZfDaWD+z9/m3hh OsRqcZD4t9t6bVT0ZxpJKljkVvq76QBB9ZNrID7PX5POCDorY77nnGDArwrBMn13GaAf J8O9XO0b0KFCOL8fJMURM/wHQ8xam63iU+EexFIaSgjzi+5QpL30id1l/tDYKe97hxV3 9aeYzsLD2r6qFbV8cVZWAPWfsrdhuCnUcZNOU/OaFH7pJpOPivsg0CcIeZaDPp7BoS6C pkkA== MIME-Version: 1.0 X-Received: by 10.180.108.148 with SMTP id hk20mr29109820wib.83.1445967618287; Tue, 27 Oct 2015 10:40:18 -0700 (PDT) Received: by 10.194.95.198 with HTTP; Tue, 27 Oct 2015 10:40:18 -0700 (PDT) In-Reply-To: <1596710.yJjYHNzsGL@xps13> References: <1434702301-4509-1-git-send-email-vido@cesnet.cz> <1442565172-5338-1-git-send-email-matejvido@gmail.com> <1442565172-5338-4-git-send-email-matejvido@gmail.com> <1596710.yJjYHNzsGL@xps13> Date: Tue, 27 Oct 2015 18:40:18 +0100 Message-ID: From: Matej Vido To: Thomas Monjalon Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Cc: dev@dpdk.org Subject: Re: [dpdk-dev] [PATCH v2 3/5] szedata2: add handling of scattered packets in TX 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, 27 Oct 2015 17:40:18 -0000 Hi Thomas, 2015-10-26 15:55 GMT+01:00 Thomas Monjalon : > Hi Matej, > > 2015-09-18 10:32, Matej Vido: > > - rte_memcpy(tmp_dst, > > - rte_pktmbuf_mtod(mbuf, const void *), > > - pkt_len); > > + if (likely(mbuf_segs == 1)) { > > + /* > > + * non-scattered packet, > > + * transmit from one mbuf > > + */ > > + rte_memcpy(tmp_dst, > > + rte_pktmbuf_mtod(mbuf, const void > *), > > + pkt_len); > > You could avoid this change by keeping "if (likely(mbuf_segs == 1))" > in the first patch. > By the way, it seems to be an abusive use of "likely". > > I will edit it in v3. Thanks. Best regards, Matej Vido