From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 0A6D0A0A0F; Wed, 7 Apr 2021 22:15:45 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id E3108140F3C; Wed, 7 Apr 2021 22:15:44 +0200 (CEST) Received: from sysclose.org (smtp.sysclose.org [69.164.214.230]) by mails.dpdk.org (Postfix) with ESMTP id B66D8140F2E for ; Wed, 7 Apr 2021 22:15:43 +0200 (CEST) Received: from localhost (unknown [45.71.105.250]) by sysclose.org (Postfix) with ESMTPSA id 91FA7327A; Wed, 7 Apr 2021 20:15:43 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 sysclose.org 91FA7327A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sysclose.org; s=201903; t=1617826543; bh=Nh2v8KpAvfhGQeOJFif17pQB0RwNbLGBRAk7I5R3sjk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=PYqf+fw4RWbDfmGdgiUE/kIAutNdyvyfCt2vpyC4zvOEbwG8yXOzRhlVMtgvUOcxB z2h5KkKpObyYB8XFW8NeHoP1e79+AqbPOspjmMiJgN++tyKa5iTy1jJ5JM/oxYIkxo WJxB/F45KoRJdbcwdqjbXUv7sUylP9xM7rZqpmEU9fSoiHKOCimEXcdUNYrwFstRA4 sHs2rTnquVwmRAhnUw3ACO89vUE71FOUX50kJVLrqEtuVzRd5BHURuWDitnrdlePNv zO3Xfdewi9hqu7xlz0KfZd7YBlSQ4oKPREkPI56uAyuyqwLk1cRJlZGOBOJoYf61rL rcMWx8/PUOnow== Date: Wed, 7 Apr 2021 17:15:39 -0300 From: Flavio Leitner To: David Marchand Cc: dev@dpdk.org, maxime.coquelin@redhat.com, olivier.matz@6wind.com, i.maximets@ovn.org, Keith Wiles Message-ID: References: <20210401095243.18211-1-david.marchand@redhat.com> <20210401095243.18211-3-david.marchand@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210401095243.18211-3-david.marchand@redhat.com> Subject: Re: [dpdk-dev] [PATCH 2/5] net/tap: do not touch Tx offload flags X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Thu, Apr 01, 2021 at 11:52:40AM +0200, David Marchand wrote: > Tx offload flags are of the application responsibility. > Leave the mbuf alone and check for TSO where needed. > > Signed-off-by: David Marchand > --- The patch looks good, but maybe a better approach would be to change the documentation to require the TCP_CKSUM flag when TCP_SEG is used, otherwise this flag adjusting needs to be replicated every time TCP_SEG is used. The above could break existing applications, so perhaps doing something like below would be better and backwards compatible? Then we can remove those places tweaking the flags completely. diff --git a/lib/librte_mbuf/rte_mbuf_core.h b/lib/librte_mbuf/rte_mbuf_core.h index c17dc95c5..6a0c2cdd9 100644 --- a/lib/librte_mbuf/rte_mbuf_core.h +++ b/lib/librte_mbuf/rte_mbuf_core.h @@ -298,7 +298,7 @@ extern "C" { * - if it's IPv4, set the PKT_TX_IP_CKSUM flag * - fill the mbuf offload information: l2_len, l3_len, l4_len, tso_segsz */ -#define PKT_TX_TCP_SEG (1ULL << 50) +#define PKT_TX_TCP_SEG (1ULL << 50) | PKT_TX_TCP_CKSUM /** TX IEEE1588 packet to timestamp. */ #define PKT_TX_IEEE1588_TMST (1ULL << 51) Thanks, fbl