From patchwork Fri Mar 20 18:14:03 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bill Fischofer X-Patchwork-Id: 46152 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wg0-f72.google.com (mail-wg0-f72.google.com [74.125.82.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id AFF6221418 for ; Fri, 20 Mar 2015 18:14:37 +0000 (UTC) Received: by wggx13 with SMTP id x13sf18558968wgg.0 for ; Fri, 20 Mar 2015 11:14:36 -0700 (PDT) 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:in-reply-to :references:cc: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=e9YYMCRz3TfLRbLCxFSRUFoREsnChTRw6uAUlVGC0aw=; b=F7dqQPtNSo5nhaIegwwpPoJMdy3LHPohM+K7NTMqgp97/+dojkjVgeyXPth+vME8NO 53vTQIclyGE2vkvM3cyEGpfGCNZGD1AK/GnrsRFywiGhpXDLRh9gDsQt4jm7gafYHzwr lvCEHJ70x4kc/VmGSBnMtEj2NJOJZZzevP4YE/oD0bo7phRs3a0qlxX0Jkr2ppPTj2as FJSuiyldHdA7scOwi+l4xc9+0Nmwihc9IKIbn2tm5WR/l3CKw1a7lDO9vhWwH3QJjyYl NG1m8lhtup/v5bPNcrUhsH3zGc3yPjdqOKYKrXVhM5nUoCbleiZu6AhaxQEQi9bNsbjR a6/g== X-Gm-Message-State: ALoCoQn3TUP1EbiNU/ew2UPGHkpFFNtitWOmYa9189cdr+Z2zNC/v6uLbV2gSzkNcTbVWhnhBzZ4 X-Received: by 10.152.20.41 with SMTP id k9mr1306328lae.10.1426875276954; Fri, 20 Mar 2015 11:14:36 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.18.225 with SMTP id z1ls472615lad.109.gmail; Fri, 20 Mar 2015 11:14:36 -0700 (PDT) X-Received: by 10.112.44.132 with SMTP id e4mr73936411lbm.66.1426875276673; Fri, 20 Mar 2015 11:14:36 -0700 (PDT) Received: from mail-la0-f43.google.com (mail-la0-f43.google.com. [209.85.215.43]) by mx.google.com with ESMTPS id s5si3617134laa.137.2015.03.20.11.14.36 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 20 Mar 2015 11:14:36 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.43 as permitted sender) client-ip=209.85.215.43; Received: by ladw1 with SMTP id w1so93306837lad.0 for ; Fri, 20 Mar 2015 11:14:36 -0700 (PDT) X-Received: by 10.152.204.197 with SMTP id la5mr4952854lac.32.1426875276230; Fri, 20 Mar 2015 11:14:36 -0700 (PDT) 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.35.133 with SMTP id h5csp209448lbj; Fri, 20 Mar 2015 11:14:35 -0700 (PDT) X-Received: by 10.52.118.9 with SMTP id ki9mr86424661vdb.11.1426875269560; Fri, 20 Mar 2015 11:14:29 -0700 (PDT) Received: from ip-10-35-177-41.ec2.internal (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTPS id cg9si4414582vdc.104.2015.03.20.11.14.28 (version=TLSv1 cipher=RC4-SHA bits=128/128); Fri, 20 Mar 2015 11:14:29 -0700 (PDT) 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 1YZ1RC-0001oB-HM; Fri, 20 Mar 2015 18:14:26 +0000 Received: from mail-oi0-f47.google.com ([209.85.218.47]) by ip-10-35-177-41.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1YZ1R4-0001nh-8i for lng-odp@lists.linaro.org; Fri, 20 Mar 2015 18:14:18 +0000 Received: by oifl3 with SMTP id l3so67820587oif.0 for ; Fri, 20 Mar 2015 11:14:13 -0700 (PDT) X-Received: by 10.60.45.165 with SMTP id o5mr25087875oem.44.1426875252999; Fri, 20 Mar 2015 11:14:12 -0700 (PDT) Received: from localhost.localdomain (cpe-24-28-70-239.austin.res.rr.com. [24.28.70.239]) by mx.google.com with ESMTPSA id by10sm2915225oec.8.2015.03.20.11.14.12 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 20 Mar 2015 11:14:12 -0700 (PDT) From: Bill Fischofer To: petri.savolainen@linaro.org Date: Fri, 20 Mar 2015 13:14:03 -0500 Message-Id: <1426875244-23072-2-git-send-email-bill.fischofer@linaro.org> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1426875244-23072-1-git-send-email-bill.fischofer@linaro.org> References: <1426875244-23072-1-git-send-email-bill.fischofer@linaro.org> X-Topics: patch Cc: lng-odp@lists.linaro.org Subject: [lng-odp] [API-NEXT PATCHv2 2/3] linux-generic: packet: use odp_bool_t for packet flag APIs 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: bill.fischofer@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.43 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 change addresses Bug https://bugs.linaro.org/show_bug.cgi?id=1334 Signed-off-by: Bill Fischofer --- platform/linux-generic/odp_packet_flags.c | 36 +++++++++++++++---------------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/platform/linux-generic/odp_packet_flags.c b/platform/linux-generic/odp_packet_flags.c index ab3d12f..8ec6b09 100644 --- a/platform/linux-generic/odp_packet_flags.c +++ b/platform/linux-generic/odp_packet_flags.c @@ -8,94 +8,94 @@ #include -int odp_packet_has_error(odp_packet_t pkt) +odp_bool_t odp_packet_has_error(odp_packet_t pkt) { return (odp_packet_hdr(pkt)->error_flags.all != 0); } /* Get Input Flags */ -int odp_packet_has_l2(odp_packet_t pkt) +odp_bool_t odp_packet_has_l2(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.l2; } -int odp_packet_has_l3(odp_packet_t pkt) +odp_bool_t odp_packet_has_l3(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.l3; } -int odp_packet_has_l4(odp_packet_t pkt) +odp_bool_t odp_packet_has_l4(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.l4; } -int odp_packet_has_eth(odp_packet_t pkt) +odp_bool_t odp_packet_has_eth(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.eth; } -int odp_packet_has_jumbo(odp_packet_t pkt) +odp_bool_t odp_packet_has_jumbo(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.jumbo; } -int odp_packet_has_vlan(odp_packet_t pkt) +odp_bool_t odp_packet_has_vlan(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.vlan; } -int odp_packet_has_vlan_qinq(odp_packet_t pkt) +odp_bool_t odp_packet_has_vlan_qinq(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.vlan_qinq; } -int odp_packet_has_arp(odp_packet_t pkt) +odp_bool_t odp_packet_has_arp(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.arp; } -int odp_packet_has_ipv4(odp_packet_t pkt) +odp_bool_t odp_packet_has_ipv4(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.ipv4; } -int odp_packet_has_ipv6(odp_packet_t pkt) +odp_bool_t odp_packet_has_ipv6(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.ipv6; } -int odp_packet_has_ipfrag(odp_packet_t pkt) +odp_bool_t odp_packet_has_ipfrag(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.ipfrag; } -int odp_packet_has_ipopt(odp_packet_t pkt) +odp_bool_t odp_packet_has_ipopt(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.ipopt; } -int odp_packet_has_ipsec(odp_packet_t pkt) +odp_bool_t odp_packet_has_ipsec(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.ipsec; } -int odp_packet_has_udp(odp_packet_t pkt) +odp_bool_t odp_packet_has_udp(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.udp; } -int odp_packet_has_tcp(odp_packet_t pkt) +odp_bool_t odp_packet_has_tcp(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.tcp; } -int odp_packet_has_sctp(odp_packet_t pkt) +odp_bool_t odp_packet_has_sctp(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.sctp; } -int odp_packet_has_icmp(odp_packet_t pkt) +odp_bool_t odp_packet_has_icmp(odp_packet_t pkt) { return odp_packet_hdr(pkt)->input_flags.icmp; }