From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.7 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id CAA3AC48BD7 for ; Thu, 27 Jun 2019 17:55:12 +0000 (UTC) Received: from dpdk.org (dpdk.org [92.243.14.124]) by mail.kernel.org (Postfix) with ESMTP id 6995120659 for ; Thu, 27 Jun 2019 17:55:12 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 6995120659 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=solarflare.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=dev-bounces@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 7C13B2BE3; Thu, 27 Jun 2019 19:55:11 +0200 (CEST) Received: from dispatch1-us1.ppe-hosted.com (dispatch1-us1.ppe-hosted.com [67.231.154.164]) by dpdk.org (Postfix) with ESMTP id F14392BA5 for ; Thu, 27 Jun 2019 19:55:09 +0200 (CEST) X-Virus-Scanned: Proofpoint Essentials engine Received: from webmail.solarflare.com (uk.solarflare.com [193.34.186.16]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mx1-us3.ppe-hosted.com (PPE Hosted ESMTP Server) with ESMTPS id 9770B980058; Thu, 27 Jun 2019 17:55:08 +0000 (UTC) Received: from [192.168.38.17] (91.220.146.112) by ukex01.SolarFlarecom.com (10.17.10.4) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Thu, 27 Jun 2019 18:55:01 +0100 To: Dekel Peled , , , , , , , CC: , References: <91371a891418062bcf88069bbd24c1cc4759f1ab.1561656978.git.dekelp@mellanox.com> From: Andrew Rybchenko Message-ID: <58b03d51-5aec-3943-cf63-0a4f93fbef4b@solarflare.com> Date: Thu, 27 Jun 2019 20:54:57 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.1 MIME-Version: 1.0 In-Reply-To: <91371a891418062bcf88069bbd24c1cc4759f1ab.1561656978.git.dekelp@mellanox.com> Content-Language: en-GB X-Originating-IP: [91.220.146.112] X-ClientProxiedBy: ocex03.SolarFlarecom.com (10.20.40.36) To ukex01.SolarFlarecom.com (10.17.10.4) X-TM-AS-Product-Ver: SMEX-12.5.0.1300-8.5.1010-24720.000 X-TM-AS-Result: No-13.192700-8.000000-10 X-TMASE-MatchedRID: 6lay9u8oTUPmLzc6AOD8DfHkpkyUphL9NV9S7O+u3KYfVuGrjP7J9IBv JfFbsOF2zi5dYQjfWjm9ETSqcPWvPDM9BBRuZZ1vcheA8ngAb/tbD9LQcHt6g70rWM4nIpJr5YG bP3uVyfKGy3RToYQakzapQY+AHKbUe8IZZuexAA0SEYfcJF0pRYeAPCkZqxntL+H1U69PoCDW3b 0otYpGPkEe/bRpAYoLI/ormZXGtKIS5iXdhf8hbj8Ckw9b/GFe3FYvKmZiVnM4XREg9Ki10+eE8 aqGofn0IcrnRrfRP6G8ArH4kh+qMRoQP43UnryWwbRQ2Bpmlio3MuSq9XdO0wwv1ZvdCH+FFXCU eF7nROZFzHrMKRZICh3DeMfpbWC9c8knU5CZtUpxBYLeFmtS7cdtmwbxPlmOtB9ItN9lSLzdKUS BW7I322+5ieh24ZYRX7bicKxRIU23sNbcHjySQQD6RpjqQGaFtVX2a1/ZsVjMtoWrbvo4OiOAZu 00tFHTwvYzgghdU50ePaeHbMuxeuJ6IADS+VHuW06+D26qgyL1Ak8PL/t/qPzv0LDRMBewR/ZTi T8lNJU= X-TM-AS-User-Approved-Sender: Yes X-TM-AS-User-Blocked-Sender: No X-TMASE-Result: 10--13.192700-8.000000 X-TMASE-Version: SMEX-12.5.0.1300-8.5.1010-24720.000 X-MDID: 1561658109-Pj0m6ygkhEHK Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 8bit X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] [PATCH v7 1/3] ethdev: add actions to modify TCP header fields X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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 6/27/19 8:39 PM, Dekel Peled wrote: > Add actions: > - INC_TCP_SEQ - Increase sequence number in the outermost TCP header. > - DEC_TCP_SEQ - Decrease sequence number in the outermost TCP header. > - INC_TCP_ACK - Increase acknowledgment number in the outermost TCP > header. > - DEC_TCP_ACK - Decrease acknowledgment number in the outermost TCP > header. > > Original work by Xiaoyu Min. > > This patch introduces a new approach, using a simple integer instead > of using an action-specific structure for each of these actions. > This approach can be later applied to modify existing actions which > require only a single integer. If we allow it, may be we should fix at least experimental API and remove dummy structures. I think ideally it should be a pre-patch which allows to avoid structures. Right now it is a mixture of two logical changes. > Signed-off-by: Dekel Peled A nit below (plus above), other than that Acked-by: Andrew Rybchenko [...] > diff --git a/lib/librte_ethdev/rte_flow.h b/lib/librte_ethdev/rte_flow.h > index f3a8fb1..8c962d0 100644 > --- a/lib/librte_ethdev/rte_flow.h > +++ b/lib/librte_ethdev/rte_flow.h > @@ -1650,6 +1650,46 @@ enum rte_flow_action_type { > * See struct rte_flow_action_set_mac. > */ > RTE_FLOW_ACTION_TYPE_SET_MAC_DST, > + > + /** > + * Increase sequence number in the outermost TCP header. > + * > + * Using this action on non-matching traffic will result in > + * undefined behavior. > + * > + * See struct rte_flow_integer_action. There is no  rte_flow_integer_action, please, fix. [...]