From patchwork Wed Dec 13 13:00:04 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Github ODP bot X-Patchwork-Id: 121766 Delivered-To: patch@linaro.org Received: by 10.140.22.227 with SMTP id 90csp5439844qgn; Wed, 13 Dec 2017 05:01:16 -0800 (PST) X-Google-Smtp-Source: ACJfBovbbOv/zlEWANoSCQDFv8qtz3Y5QUK5K6ds9JUt8ZAKY2tBNgy4SFagCDKYZ85phYyTv3Sk X-Received: by 10.200.38.33 with SMTP id u30mr11254105qtu.197.1513170076743; Wed, 13 Dec 2017 05:01:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1513170076; cv=none; d=google.com; s=arc-20160816; b=beUxhAiwk9ppVG6EmVZUZO26ESriS8YC4b9E6+o4rjPKqR43FeGkqg+oJkBMUe8Ags LaPqOgmRqnzVWQEzYsrdaSCmVvVdhDe/DbzzJ9OJVDGzOBmlXIm4pI/FgtfwnHRxqBz+ 0mQSvAg2VtPDiQyZI/4V3ks59r9J9SKQcoaOuSL4BMZK9Mkp6NmHUSK+9KOglG3L1pEy BIuWZ0BqSiRY/YPFDAdVgaHww0hGIauBiNO6Uixydz+vR2NNYpL/IyOJVh6uoR9sZdTa A1jDUueZBKqAiGC9O6Y6MmJuyy06W+nNf6YIoJYAVjaupz7dPX8LllNkLm3uQchdcpOI sutA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:github-pr-num :references:in-reply-to:message-id:date:to:from:delivered-to :arc-authentication-results; bh=IrPByqZoVg1NXnaEOxb/niEmM6n/rbxm8TMgrB8c96k=; b=wZj3kfyW8R8bMTYxr5ImiH2fab1Qt4L3qNGflHFDiYaeKENlKviehnpmUKeJN/xgv8 a6Pp62YrzIHN8RlUuuPPtXAcJSYSwDTfSD0YftCiOxouds/ErqkEqgV2/UnrHyBm6bYV 6LYzdIRI+BiEJ+eICRi9eIBLaGfP+BiAufE6mrMjiSbA2+Qb8x4mh5Ct7+0mXks0Y+fQ t46VMwAp2e5nBDGgtQos+OhMpZnBpoyztTKtwLhLu9RDXNoN7kh8LnSdjH9ZD2ixiEWT 0DDdY6RARw+ORb3mOHjv3mrmD7wc/jewBFEH1fIwMK4kzGyE5gw1KdkC4/r+cHBc7r8f kBew== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=yandex.ru Return-Path: Received: from lists.linaro.org (ec2-54-197-127-237.compute-1.amazonaws.com. [54.197.127.237]) by mx.google.com with ESMTP id 1si1763847qkh.355.2017.12.13.05.01.16; Wed, 13 Dec 2017 05:01:16 -0800 (PST) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) client-ip=54.197.127.237; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=yandex.ru Received: by lists.linaro.org (Postfix, from userid 109) id 68D7260732; Wed, 13 Dec 2017 13:01:16 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-5.4 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id D13DD6086F; Wed, 13 Dec 2017 13:00:36 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 243F0607FB; Wed, 13 Dec 2017 13:00:31 +0000 (UTC) Received: from forward103p.mail.yandex.net (forward103p.mail.yandex.net [77.88.28.106]) by lists.linaro.org (Postfix) with ESMTPS id C400960655 for ; Wed, 13 Dec 2017 13:00:24 +0000 (UTC) Received: from mxback14j.mail.yandex.net (mxback14j.mail.yandex.net [IPv6:2a02:6b8:0:1619::90]) by forward103p.mail.yandex.net (Yandex) with ESMTP id 548D02183E9F for ; Wed, 13 Dec 2017 16:00:23 +0300 (MSK) Received: from smtp2p.mail.yandex.net (smtp2p.mail.yandex.net [2a02:6b8:0:1472:2741:0:8b6:7]) by mxback14j.mail.yandex.net (nwsmtp/Yandex) with ESMTP id rmdTZQgEvH-0NZ8TJqO; Wed, 13 Dec 2017 16:00:23 +0300 Received: by smtp2p.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id ZKo7wGnMCt-0GUa95pw; Wed, 13 Dec 2017 16:00:16 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (Client certificate not present) From: Github ODP bot To: lng-odp@lists.linaro.org Date: Wed, 13 Dec 2017 16:00:04 +0300 Message-Id: <1513170009-9281-2-git-send-email-odpbot@yandex.ru> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1513170009-9281-1-git-send-email-odpbot@yandex.ru> References: <1513170009-9281-1-git-send-email-odpbot@yandex.ru> Github-pr-num: 338 Subject: [lng-odp] [PATCH API-NEXT v1 1/6] api: pktio: start switching to using odp_proto_layer_t X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" From: Dmitry Eremin-Solenikov Instead of using separate odp_pktio_parser_layer_t switch to using odp_proto_layer_t. Deprecate old enum and values. For now do not put them under ODP_DEPRECATED_API to let the rest of ODP code to adapt. Signed-off-by: Dmitry Eremin-Solenikov --- /** Email created from pull request 338 (lumag:pktio_parse_layer) ** https://github.com/Linaro/odp/pull/338 ** Patch: https://github.com/Linaro/odp/pull/338.patch ** Base sha: d96a8207591fbcaac25b79286d7d72a537354c1f ** Merge commit sha: 874b90ec6730e9189edd69774044ef32d7f0d95f **/ include/odp/api/spec/packet_io.h | 38 ++++++++++++++++++++++---------------- 1 file changed, 22 insertions(+), 16 deletions(-) diff --git a/include/odp/api/spec/packet_io.h b/include/odp/api/spec/packet_io.h index a3312d280..bf30877f5 100644 --- a/include/odp/api/spec/packet_io.h +++ b/include/odp/api/spec/packet_io.h @@ -272,8 +272,8 @@ typedef struct odp_pktio_param_t { * not checked. * * IPv4 checksum checking may be enabled only when parsing level is - * ODP_PKTIO_PARSER_LAYER_L3 or higher. Similarly, L4 level checksum checking - * may be enabled only with parsing level ODP_PKTIO_PARSER_LAYER_L4 or higher. + * ODP_PROTO_LAYER_L3 or higher. Similarly, L4 level checksum checking + * may be enabled only with parsing level ODP_PROTO_LAYER_L4 or higher. * * Whether checksum checking was done and whether a checksum was correct * can be queried for each received packet with odp_packet_l3_chksum_status() @@ -405,24 +405,30 @@ typedef union odp_pktout_config_opt_t { /** * Parser layers + * + * @deprecated Use odp_proto_layer_t instead */ -typedef enum odp_pktio_parser_layer_t { - /** No layers */ - ODP_PKTIO_PARSER_LAYER_NONE = ODP_PROTO_LAYER_NONE, +typedef odp_proto_layer_t odp_pktio_parser_layer_t; - /** Layer L2 protocols (Ethernet, VLAN, ARP, etc) */ - ODP_PKTIO_PARSER_LAYER_L2 = ODP_PROTO_LAYER_L2, +/** No layers + * @deprecated Use ODP_PROTO_LAYER_NONE, instead */ +#define ODP_PKTIO_PARSER_LAYER_NONE ODP_PROTO_LAYER_NONE - /** Layer L3 protocols (IPv4, IPv6, ICMP, IPsec, etc) */ - ODP_PKTIO_PARSER_LAYER_L3 = ODP_PROTO_LAYER_L3, +/** Layer L2 protocols (Ethernet, VLAN, ARP, etc) + * @deprecated Use ODP_PROTO_LAYER_L2, instead */ +#define ODP_PKTIO_PARSER_LAYER_L2 ODP_PROTO_LAYER_L2 - /** Layer L4 protocols (UDP, TCP, SCTP) */ - ODP_PKTIO_PARSER_LAYER_L4 = ODP_PROTO_LAYER_L4, +/** Layer L3 protocols (IPv4, IPv6, ICMP, IPsec, etc) + * @deprecated Use ODP_PROTO_LAYER_L3, instead */ +#define ODP_PKTIO_PARSER_LAYER_L3 ODP_PROTO_LAYER_L3 - /** All layers */ - ODP_PKTIO_PARSER_LAYER_ALL = ODP_PROTO_LAYER_ALL +/** Layer L4 protocols (UDP, TCP, SCTP) + * @deprecated Use ODP_PROTO_LAYER_L4, instead */ +#define ODP_PKTIO_PARSER_LAYER_L4 ODP_PROTO_LAYER_L4 -} odp_pktio_parser_layer_t; +/** All layers + * @deprecated Use ODP_PROTO_LAYER_ALL instead */ +#define ODP_PKTIO_PARSER_LAYER_ALL ODP_PROTO_LAYER_ALL /** * Parser configuration @@ -436,8 +442,8 @@ typedef struct odp_pktio_parser_config_t { * set. In addition, offset (and pointer) to the next layer is set. * Other layer/protocol specific metadata have undefined values. * - * The default value is ODP_PKTIO_PARSER_LAYER_ALL. */ - odp_pktio_parser_layer_t layer; + * The default value is ODP_PROTO_LAYER_ALL. */ + odp_proto_layer_t layer; } odp_pktio_parser_config_t;