From patchwork Tue Dec 9 12:06:07 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Uvarov X-Patchwork-Id: 42047 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wi0-f198.google.com (mail-wi0-f198.google.com [209.85.212.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 77D8E244AC for ; Tue, 9 Dec 2014 12:06:34 +0000 (UTC) Received: by mail-wi0-f198.google.com with SMTP id r20sf642435wiv.9 for ; Tue, 09 Dec 2014 04:06:33 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:date:message-id:subject :precedence:list-id:list-unsubscribe:list-archive:list-post :list-help:list-subscribe:mime-version:content-type :content-transfer-encoding:errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list; bh=g1HnWaS0sEbUC4tqk7bwEdi+2T8VtFCTdU8ivotWHWs=; b=VlobgRJbQsqEZT04d6zf5toh7FWawX5E/09BwdPVNCj7egiAa+o+I7LO1UyKE/GFD/ rLpN/THb/P5PSH8cxF72MeH4pf06IhYDyFXUF0CAn/bTYikvlBKViq9/y8LaRRSM2Xim 3s0ScSr37tb5U7XiIYyvvJz//5kApLvaxuIEmI60dxPL5MNRQ3i/QPUwf5OkTbgXgZzI PS4G97Gmgq1FLFjx5oFJYktl3GUA2QbwP3ephtDeMWWzkCmM6JdPKyVt2zkA0s6ccO79 tJEOjIWj/TIjrcWfP1oyEJYsWrrWUFLXB1SPsQY8iJ/xKTuNfzbFKJS0UWAb+6fKCSNm pMOA== X-Gm-Message-State: ALoCoQlraf6aIvhyaVHO9E+d/oRlx3QDfLTJVIHdj4ksK1gyM29OB21uJrM+IkbTtHyk5a1WAlDH X-Received: by 10.194.173.97 with SMTP id bj1mr6465117wjc.2.1418126793765; Tue, 09 Dec 2014 04:06:33 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.88.99 with SMTP id bf3ls32267lab.13.gmail; Tue, 09 Dec 2014 04:06:33 -0800 (PST) X-Received: by 10.152.234.35 with SMTP id ub3mr21710198lac.70.1418126793593; Tue, 09 Dec 2014 04:06:33 -0800 (PST) Received: from mail-la0-f51.google.com (mail-la0-f51.google.com. [209.85.215.51]) by mx.google.com with ESMTPS id pg4si1128827lbb.55.2014.12.09.04.06.33 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 09 Dec 2014 04:06:33 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.51 as permitted sender) client-ip=209.85.215.51; Received: by mail-la0-f51.google.com with SMTP id ms9so360699lab.38 for ; Tue, 09 Dec 2014 04:06:33 -0800 (PST) X-Received: by 10.112.235.196 with SMTP id uo4mr21149666lbc.66.1418126793401; Tue, 09 Dec 2014 04:06:33 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.184.201 with SMTP id ew9csp741848lbc; Tue, 9 Dec 2014 04:06:32 -0800 (PST) X-Received: by 10.140.21.167 with SMTP id 36mr3594383qgl.25.1418126791748; Tue, 09 Dec 2014 04:06:31 -0800 (PST) Received: from ip-10-35-177-41.ec2.internal (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTPS id 79si962294qgj.60.2014.12.09.04.06.30 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Tue, 09 Dec 2014 04:06:31 -0800 (PST) Received-SPF: none (google.com: lng-odp-bounces@lists.linaro.org does not designate permitted sender hosts) client-ip=54.225.227.206; Received: from localhost ([127.0.0.1] helo=ip-10-35-177-41.ec2.internal) by ip-10-35-177-41.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1XyJYi-0001VX-C4; Tue, 09 Dec 2014 12:06:28 +0000 Received: from mail-lb0-f172.google.com ([209.85.217.172]) by ip-10-35-177-41.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1XyJYb-0001VS-JV for lng-odp@lists.linaro.org; Tue, 09 Dec 2014 12:06:21 +0000 Received: by mail-lb0-f172.google.com with SMTP id u10so373789lbd.3 for ; Tue, 09 Dec 2014 04:06:16 -0800 (PST) X-Received: by 10.112.166.101 with SMTP id zf5mr22288776lbb.42.1418126775844; Tue, 09 Dec 2014 04:06:15 -0800 (PST) Received: from localhost.localdomain (ppp91-76-163-205.pppoe.mtu-net.ru. [91.76.163.205]) by mx.google.com with ESMTPSA id w3sm305401law.36.2014.12.09.04.06.14 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 09 Dec 2014 04:06:14 -0800 (PST) From: Maxim Uvarov To: lng-odp@lists.linaro.org Date: Tue, 9 Dec 2014 15:06:07 +0300 Message-Id: <1418126767-18411-1-git-send-email-maxim.uvarov@linaro.org> X-Mailer: git-send-email 1.8.5.1.163.gd7aced9 X-Topics: patch Subject: [lng-odp] [PATCHv2] Rename packet functions X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , MIME-Version: 1.0 Errors-To: lng-odp-bounces@lists.linaro.org Sender: lng-odp-bounces@lists.linaro.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: maxim.uvarov@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.51 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 This patch updates the ODP example programs to reflect the specified odp_packet_flags.h API name changes. Signed-off-by: Maxim Uvarov Reviewed-by: Bill Fischofer --- example/generator/odp_generator.c | 2 +- example/ipsec/odp_ipsec.c | 4 +- example/ipsec/odp_ipsec_stream.c | 4 +- example/packet/odp_pktio.c | 4 +- .../linux-generic/include/api/odp_packet_flags.h | 70 +++++++++++----------- platform/linux-generic/odp_packet_flags.c | 70 +++++++++++----------- 6 files changed, 77 insertions(+), 77 deletions(-) diff --git a/example/generator/odp_generator.c b/example/generator/odp_generator.c index 73b0369..8c227bc 100644 --- a/example/generator/odp_generator.c +++ b/example/generator/odp_generator.c @@ -401,7 +401,7 @@ static void print_pkts(int thr, odp_packet_t pkt_tbl[], unsigned len) rlen = 0; /* only ip pkts */ - if (!odp_packet_inflag_ipv4(pkt)) + if (!odp_packet_has_ipv4(pkt)) continue; odp_atomic_inc_u64(&counters.ip); diff --git a/example/ipsec/odp_ipsec.c b/example/ipsec/odp_ipsec.c index 76d27c5..aeeb1ba 100644 --- a/example/ipsec/odp_ipsec.c +++ b/example/ipsec/odp_ipsec.c @@ -625,10 +625,10 @@ pkt_disposition_e do_input_verify(odp_packet_t pkt, if (odp_unlikely(odp_packet_error(pkt))) return PKT_DROP; - if (!odp_packet_inflag_eth(pkt)) + if (!odp_packet_has_eth(pkt)) return PKT_DROP; - if (!odp_packet_inflag_ipv4(pkt)) + if (!odp_packet_has_ipv4(pkt)) return PKT_DROP; return PKT_CONTINUE; diff --git a/example/ipsec/odp_ipsec_stream.c b/example/ipsec/odp_ipsec_stream.c index 139d00e..8e002b6 100644 --- a/example/ipsec/odp_ipsec_stream.c +++ b/example/ipsec/odp_ipsec_stream.c @@ -198,7 +198,7 @@ odp_packet_t create_ipv4_packet(stream_db_entry_t *stream, data = odp_packet_data(pkt); /* Ethernet */ - odp_packet_set_inflag_eth(pkt, 1); + odp_packet_has_eth_set(pkt, 1); odp_packet_set_l2_offset(pkt, data - base); eth = (odph_ethhdr_t *)data; data += sizeof(*eth); @@ -208,7 +208,7 @@ odp_packet_t create_ipv4_packet(stream_db_entry_t *stream, eth->type = odp_cpu_to_be_16(ODPH_ETHTYPE_IPV4); /* IPv4 */ - odp_packet_set_inflag_ipv4(pkt, 1); + odp_packet_has_ipv4_set(pkt, 1); odp_packet_set_l3_offset(pkt, data - base); ip = (odph_ipv4hdr_t *)data; data += sizeof(*ip); diff --git a/example/packet/odp_pktio.c b/example/packet/odp_pktio.c index 7d51682..eceee15 100644 --- a/example/packet/odp_pktio.c +++ b/example/packet/odp_pktio.c @@ -495,14 +495,14 @@ static void swap_pkt_addrs(odp_packet_t pkt_tbl[], unsigned len) for (i = 0; i < len; ++i) { pkt = pkt_tbl[i]; - if (odp_packet_inflag_eth(pkt)) { + if (odp_packet_has_eth(pkt)) { eth = (odph_ethhdr_t *)odp_packet_l2(pkt); tmp_addr = eth->dst; eth->dst = eth->src; eth->src = tmp_addr; - if (odp_packet_inflag_ipv4(pkt)) { + if (odp_packet_has_ipv4(pkt)) { /* IPv4 */ ip = (odph_ipv4hdr_t *)odp_packet_l3(pkt); diff --git a/platform/linux-generic/include/api/odp_packet_flags.h b/platform/linux-generic/include/api/odp_packet_flags.h index ccaa04f..24c4065 100644 --- a/platform/linux-generic/include/api/odp_packet_flags.h +++ b/platform/linux-generic/include/api/odp_packet_flags.h @@ -50,7 +50,7 @@ int odp_packet_errflag_frame_len(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains a valid & known L2 header, 0 otherwise */ -int odp_packet_inflag_l2(odp_packet_t pkt); +int odp_packet_has_l2(odp_packet_t pkt); /** * Check for L3 header, e.g. IPv4, IPv6 @@ -58,7 +58,7 @@ int odp_packet_inflag_l2(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains a valid & known L3 header, 0 otherwise */ -int odp_packet_inflag_l3(odp_packet_t pkt); +int odp_packet_has_l3(odp_packet_t pkt); /** * Check for L4 header, e.g. UDP, TCP, SCTP (also ICMP) @@ -66,7 +66,7 @@ int odp_packet_inflag_l3(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains a valid & known L4 header, 0 otherwise */ -int odp_packet_inflag_l4(odp_packet_t pkt); +int odp_packet_has_l4(odp_packet_t pkt); /** * Check for Ethernet header @@ -74,7 +74,7 @@ int odp_packet_inflag_l4(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains a valid eth header, 0 otherwise */ -int odp_packet_inflag_eth(odp_packet_t pkt); +int odp_packet_has_eth(odp_packet_t pkt); /** * Check for jumbo frame @@ -82,7 +82,7 @@ int odp_packet_inflag_eth(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains jumbo frame, 0 otherwise */ -int odp_packet_inflag_jumbo(odp_packet_t pkt); +int odp_packet_has_jumbo(odp_packet_t pkt); /** * Check for VLAN @@ -90,7 +90,7 @@ int odp_packet_inflag_jumbo(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains a VLAN header, 0 otherwise */ -int odp_packet_inflag_vlan(odp_packet_t pkt); +int odp_packet_has_vlan(odp_packet_t pkt); /** * Check for VLAN QinQ (stacked VLAN) @@ -98,7 +98,7 @@ int odp_packet_inflag_vlan(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains a VLAN QinQ header, 0 otherwise */ -int odp_packet_inflag_vlan_qinq(odp_packet_t pkt); +int odp_packet_has_vlan_qinq(odp_packet_t pkt); /** * Check for ARP @@ -106,7 +106,7 @@ int odp_packet_inflag_vlan_qinq(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains an ARP header, 0 otherwise */ -int odp_packet_inflag_arp(odp_packet_t pkt); +int odp_packet_has_arp(odp_packet_t pkt); /** * Check for IPv4 @@ -114,7 +114,7 @@ int odp_packet_inflag_arp(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains an IPv4 header, 0 otherwise */ -int odp_packet_inflag_ipv4(odp_packet_t pkt); +int odp_packet_has_ipv4(odp_packet_t pkt); /** * Check for IPv6 @@ -122,7 +122,7 @@ int odp_packet_inflag_ipv4(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains an IPv6 header, 0 otherwise */ -int odp_packet_inflag_ipv6(odp_packet_t pkt); +int odp_packet_has_ipv6(odp_packet_t pkt); /** * Check for IP fragment @@ -130,7 +130,7 @@ int odp_packet_inflag_ipv6(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet is an IP fragment, 0 otherwise */ -int odp_packet_inflag_ipfrag(odp_packet_t pkt); +int odp_packet_has_ipfrag(odp_packet_t pkt); /** * Check for IP options @@ -138,7 +138,7 @@ int odp_packet_inflag_ipfrag(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains IP options, 0 otherwise */ -int odp_packet_inflag_ipopt(odp_packet_t pkt); +int odp_packet_has_ipopt(odp_packet_t pkt); /** * Check for IPSec @@ -146,7 +146,7 @@ int odp_packet_inflag_ipopt(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet requires IPSec processing, 0 otherwise */ -int odp_packet_inflag_ipsec(odp_packet_t pkt); +int odp_packet_has_ipsec(odp_packet_t pkt); /** * Check for UDP @@ -154,7 +154,7 @@ int odp_packet_inflag_ipsec(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains a UDP header, 0 otherwise */ -int odp_packet_inflag_udp(odp_packet_t pkt); +int odp_packet_has_udp(odp_packet_t pkt); /** * Check for TCP @@ -162,7 +162,7 @@ int odp_packet_inflag_udp(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains a TCP header, 0 otherwise */ -int odp_packet_inflag_tcp(odp_packet_t pkt); +int odp_packet_has_tcp(odp_packet_t pkt); /** * Check for SCTP @@ -170,7 +170,7 @@ int odp_packet_inflag_tcp(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains an SCTP header, 0 otherwise */ -int odp_packet_inflag_sctp(odp_packet_t pkt); +int odp_packet_has_sctp(odp_packet_t pkt); /** * Check for ICMP @@ -178,14 +178,14 @@ int odp_packet_inflag_sctp(odp_packet_t pkt); * @param pkt Packet handle * @return 1 if packet contains an ICMP header, 0 otherwise */ -int odp_packet_inflag_icmp(odp_packet_t pkt); +int odp_packet_has_icmp(odp_packet_t pkt); /** * Request L4 checksum calculation * * @param pkt Packet handle */ -void odp_packet_outflag_l4_chksum(odp_packet_t pkt); +void odp_packet_override_l4_chksum(odp_packet_t pkt); /** * Set flag for L2 header, e.g. ethernet @@ -193,7 +193,7 @@ void odp_packet_outflag_l4_chksum(odp_packet_t pkt); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_l2(odp_packet_t pkt, int val); +void odp_packet_has_l2_set(odp_packet_t pkt, int val); /** * Set flag for L3 header, e.g. IPv4, IPv6 @@ -201,7 +201,7 @@ void odp_packet_set_inflag_l2(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_l3(odp_packet_t pkt, int val); +void odp_packet_has_l3_set(odp_packet_t pkt, int val); /** * Set flag for L4 header, e.g. UDP, TCP, SCTP (also ICMP) @@ -209,7 +209,7 @@ void odp_packet_set_inflag_l3(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_l4(odp_packet_t pkt, int val); +void odp_packet_has_l4_set(odp_packet_t pkt, int val); /** * Set flag for Ethernet header @@ -217,7 +217,7 @@ void odp_packet_set_inflag_l4(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_eth(odp_packet_t pkt, int val); +void odp_packet_has_eth_set(odp_packet_t pkt, int val); /** * Set flag for jumbo frame @@ -225,7 +225,7 @@ void odp_packet_set_inflag_eth(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_jumbo(odp_packet_t pkt, int val); +void odp_packet_has_jumbo_set(odp_packet_t pkt, int val); /** * Set flag for VLAN @@ -233,7 +233,7 @@ void odp_packet_set_inflag_jumbo(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_vlan(odp_packet_t pkt, int val); +void odp_packet_has_vlan_set(odp_packet_t pkt, int val); /** * Set flag for VLAN QinQ (stacked VLAN) @@ -241,7 +241,7 @@ void odp_packet_set_inflag_vlan(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_vlan_qinq(odp_packet_t pkt, int val); +void odp_packet_has_vlan_qinq_set(odp_packet_t pkt, int val); /** * Set flag for ARP @@ -249,7 +249,7 @@ void odp_packet_set_inflag_vlan_qinq(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_arp(odp_packet_t pkt, int val); +void odp_packet_has_arp_set(odp_packet_t pkt, int val); /** * Set flag for IPv4 @@ -257,7 +257,7 @@ void odp_packet_set_inflag_arp(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_ipv4(odp_packet_t pkt, int val); +void odp_packet_has_ipv4_set(odp_packet_t pkt, int val); /** * Set flag for IPv6 @@ -265,7 +265,7 @@ void odp_packet_set_inflag_ipv4(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_ipv6(odp_packet_t pkt, int val); +void odp_packet_has_ipv6_set(odp_packet_t pkt, int val); /** * Set flag for IP fragment @@ -273,7 +273,7 @@ void odp_packet_set_inflag_ipv6(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_ipfrag(odp_packet_t pkt, int val); +void odp_packet_has_ipfrag_set(odp_packet_t pkt, int val); /** * Set flag for IP options @@ -281,7 +281,7 @@ void odp_packet_set_inflag_ipfrag(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_ipopt(odp_packet_t pkt, int val); +void odp_packet_has_ipopt_set(odp_packet_t pkt, int val); /** * Set flag for IPSec @@ -289,7 +289,7 @@ void odp_packet_set_inflag_ipopt(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_ipsec(odp_packet_t pkt, int val); +void odp_packet_has_ipsec_set(odp_packet_t pkt, int val); /** * Set flag for UDP @@ -297,7 +297,7 @@ void odp_packet_set_inflag_ipsec(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_udp(odp_packet_t pkt, int val); +void odp_packet_has_udp_set(odp_packet_t pkt, int val); /** * Set flag for TCP @@ -305,7 +305,7 @@ void odp_packet_set_inflag_udp(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_tcp(odp_packet_t pkt, int val); +void odp_packet_has_tcp_set(odp_packet_t pkt, int val); /** * Set flag for SCTP @@ -313,7 +313,7 @@ void odp_packet_set_inflag_tcp(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_sctp(odp_packet_t pkt, int val); +void odp_packet_has_sctp_set(odp_packet_t pkt, int val); /** * Set flag for ICMP @@ -321,7 +321,7 @@ void odp_packet_set_inflag_sctp(odp_packet_t pkt, int val); * @param pkt Packet handle * @param val Value */ -void odp_packet_set_inflag_icmp(odp_packet_t pkt, int val); +void odp_packet_has_icmp_set(odp_packet_t pkt, int val); /** * @} diff --git a/platform/linux-generic/odp_packet_flags.c b/platform/linux-generic/odp_packet_flags.c index 06fdeed..3f0ea9f 100644 --- a/platform/linux-generic/odp_packet_flags.c +++ b/platform/linux-generic/odp_packet_flags.c @@ -22,181 +22,181 @@ int odp_packet_errflag_frame_len(odp_packet_t pkt) /* Get Input Flags */ -int odp_packet_inflag_l2(odp_packet_t pkt) +int odp_packet_has_l2(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.l2; } -int odp_packet_inflag_l3(odp_packet_t pkt) +int odp_packet_has_l3(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.l3; } -int odp_packet_inflag_l4(odp_packet_t pkt) +int odp_packet_has_l4(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.l4; } -int odp_packet_inflag_eth(odp_packet_t pkt) +int odp_packet_has_eth(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.eth; } -int odp_packet_inflag_jumbo(odp_packet_t pkt) +int odp_packet_has_jumbo(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.jumbo; } -int odp_packet_inflag_vlan(odp_packet_t pkt) +int odp_packet_has_vlan(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.vlan; } -int odp_packet_inflag_vlan_qinq(odp_packet_t pkt) +int odp_packet_has_vlan_qinq(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.vlan_qinq; } -int odp_packet_inflag_arp(odp_packet_t pkt) +int odp_packet_has_arp(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.arp; } -int odp_packet_inflag_ipv4(odp_packet_t pkt) +int odp_packet_has_ipv4(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.ipv4; } -int odp_packet_inflag_ipv6(odp_packet_t pkt) +int odp_packet_has_ipv6(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.ipv6; } -int odp_packet_inflag_ipfrag(odp_packet_t pkt) +int odp_packet_has_ipfrag(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.ipfrag; } -int odp_packet_inflag_ipopt(odp_packet_t pkt) +int odp_packet_has_ipopt(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.ipopt; } -int odp_packet_inflag_ipsec(odp_packet_t pkt) +int odp_packet_has_ipsec(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.ipsec; } -int odp_packet_inflag_udp(odp_packet_t pkt) +int odp_packet_has_udp(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.udp; } -int odp_packet_inflag_tcp(odp_packet_t pkt) +int odp_packet_has_tcp(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.tcp; } -int odp_packet_inflag_sctp(odp_packet_t pkt) +int odp_packet_has_sctp(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.sctp; } -int odp_packet_inflag_icmp(odp_packet_t pkt) +int odp_packet_has_icmp(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.icmp; } /* Set Output Flags */ -void odp_packet_outflag_l4_chksum(odp_packet_t pkt) +void odp_packet_override_l4_chksum(odp_packet_t pkt) { odp_packet_hdr(pkt)->output_flags.l4_chksum = 1; } /* Set Input Flags */ -void odp_packet_set_inflag_l2(odp_packet_t pkt, int val) +void odp_packet_has_l2_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.l2 = val; } -void odp_packet_set_inflag_l3(odp_packet_t pkt, int val) +void odp_packet_has_l3_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.l3 = val; } -void odp_packet_set_inflag_l4(odp_packet_t pkt, int val) +void odp_packet_has_l4_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.l4 = val; } -void odp_packet_set_inflag_eth(odp_packet_t pkt, int val) +void odp_packet_has_eth_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.eth = val; } -void odp_packet_set_inflag_jumbo(odp_packet_t pkt, int val) +void odp_packet_has_jumbo_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.jumbo = val; } -void odp_packet_set_inflag_vlan(odp_packet_t pkt, int val) +void odp_packet_has_vlan_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.vlan = val; } -void odp_packet_set_inflag_vlan_qinq(odp_packet_t pkt, int val) +void odp_packet_has_vlan_qinq_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.vlan_qinq = val; } -void odp_packet_set_inflag_arp(odp_packet_t pkt, int val) +void odp_packet_has_arp_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.arp = val; } -void odp_packet_set_inflag_ipv4(odp_packet_t pkt, int val) +void odp_packet_has_ipv4_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.ipv4 = val; } -void odp_packet_set_inflag_ipv6(odp_packet_t pkt, int val) +void odp_packet_has_ipv6_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.ipv6 = val; } -void odp_packet_set_inflag_ipfrag(odp_packet_t pkt, int val) +void odp_packet_has_ipfrag_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.ipfrag = val; } -void odp_packet_set_inflag_ipopt(odp_packet_t pkt, int val) +void odp_packet_has_ipopt_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.ipopt = val; } -void odp_packet_set_inflag_ipsec(odp_packet_t pkt, int val) +void odp_packet_has_ipsec_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.ipsec = val; } -void odp_packet_set_inflag_udp(odp_packet_t pkt, int val) +void odp_packet_has_udp_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.udp = val; } -void odp_packet_set_inflag_tcp(odp_packet_t pkt, int val) +void odp_packet_has_tcp_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.tcp = val; } -void odp_packet_set_inflag_sctp(odp_packet_t pkt, int val) +void odp_packet_has_sctp_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.sctp = val; } -void odp_packet_set_inflag_icmp(odp_packet_t pkt, int val) +void odp_packet_has_icmp_set(odp_packet_t pkt, int val) { odp_packet_hdr(pkt)->input_flags.icmp = val; }