From patchwork Wed May 27 15:50:56 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bill Fischofer X-Patchwork-Id: 49017 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f72.google.com (mail-la0-f72.google.com [209.85.215.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id C617D20BF2 for ; Wed, 27 May 2015 15:51:34 +0000 (UTC) Received: by lani11 with SMTP id i11sf4071272lan.3 for ; Wed, 27 May 2015 08:51:33 -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: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=z+8qy0iIVat3e7ROXPibNwhKwoWmN4c9FeNTkUX0z3c=; b=nJQjYpqmWOmAtDclAiQtnRDKS5b7RnXtkZuJx3lSERhN7S/wp4HdH3x5vF8jT1MwRX RY7/T5RssA1o4l1i3SJ9THeHooqBe/JzGKNZkyMZQPNdYPrh5iaoToa+gH0oNKysvJEH XoCHuZz0g74COhH20v6CLaX22Vmj/TIvzpZiUwFDLqId2Cb4aNYIqUJAqD9Vy+xmLyO8 JLhwhtmVTnyRu6yxOdTZ4Sp+4QT2hNTI2eC/mIwiJWiBmCNd7ca26j1yszsN2hZLdB8r HRBkKZZtjHs4X3m1MBYpnDGCtFlakv/8jVgxHhr//wMYFEG2y4XYa7alS8Q4Dl7kY9UB TnJg== X-Gm-Message-State: ALoCoQkUl082sV5CROBa6TMdTk8/sdcV0yAB5HIPTjuxGrSU/rd4UbjEcbXRvbZShZ61RaH0T98P X-Received: by 10.112.189.131 with SMTP id gi3mr32940086lbc.6.1432741893073; Wed, 27 May 2015 08:51:33 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.5.131 with SMTP id s3ls64724las.65.gmail; Wed, 27 May 2015 08:51:32 -0700 (PDT) X-Received: by 10.152.5.198 with SMTP id u6mr28233449lau.48.1432741892924; Wed, 27 May 2015 08:51:32 -0700 (PDT) Received: from mail-la0-f50.google.com (mail-la0-f50.google.com. [209.85.215.50]) by mx.google.com with ESMTPS id h8si13946260laf.74.2015.05.27.08.51.32 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 May 2015 08:51:32 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.50 as permitted sender) client-ip=209.85.215.50; Received: by laat2 with SMTP id t2so10695862laa.1 for ; Wed, 27 May 2015 08:51:32 -0700 (PDT) X-Received: by 10.152.206.75 with SMTP id lm11mr28053355lac.41.1432741892303; Wed, 27 May 2015 08:51:32 -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.108.230 with SMTP id hn6csp466846lbb; Wed, 27 May 2015 08:51:31 -0700 (PDT) X-Received: by 10.140.92.173 with SMTP id b42mr41692355qge.54.1432741890983; Wed, 27 May 2015 08:51:30 -0700 (PDT) Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id h199si18346173qhc.33.2015.05.27.08.51.30; Wed, 27 May 2015 08:51:30 -0700 (PDT) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Received: by lists.linaro.org (Postfix, from userid 109) id E1D8F61E38; Wed, 27 May 2015 15:51:29 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252.ec2.internal X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from ip-10-142-244-252.ec2.internal (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 6758C61E2F; Wed, 27 May 2015 15:51:26 +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 4E52B61E36; Wed, 27 May 2015 15:51:22 +0000 (UTC) Received: from mail-ob0-f178.google.com (mail-ob0-f178.google.com [209.85.214.178]) by lists.linaro.org (Postfix) with ESMTPS id 14D7661E36 for ; Wed, 27 May 2015 15:51:01 +0000 (UTC) Received: by obbea2 with SMTP id ea2so10802044obb.3 for ; Wed, 27 May 2015 08:51:00 -0700 (PDT) X-Received: by 10.202.217.68 with SMTP id q65mr16381878oig.17.1432741860645; Wed, 27 May 2015 08:51:00 -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 l5sm10884493oey.5.2015.05.27.08.51.00 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 27 May 2015 08:51:00 -0700 (PDT) From: Bill Fischofer To: lng-odp@lists.linaro.org Date: Wed, 27 May 2015 10:50:56 -0500 Message-Id: <1432741856-17199-1-git-send-email-bill.fischofer@linaro.org> X-Mailer: git-send-email 2.1.0 X-Topics: patch Subject: [lng-odp] [API-NEXT PATCH 2/2] api-next: packet: clarify use of 0 len on odp_packet_alloc() X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 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" 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.50 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 Signed-off-by: Bill Fischofer Reviewed-by: Zoltan Kiss --- include/odp/api/packet.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/include/odp/api/packet.h b/include/odp/api/packet.h index 3a454b5..ea124df 100644 --- a/include/odp/api/packet.h +++ b/include/odp/api/packet.h @@ -73,6 +73,16 @@ extern "C" { * @note The default headroom and tailroom used for packets is specified by * the ODP_CONFIG_PACKET_HEADROOM and ODP_CONFIG_PACKET_TAILROOM defines in * odp_config.h. + * + * @note The len parameter sets the initial length of the allocated packet. + * If specified as 0, the implementation will allocate a packet of a default + * length chosen by the implementation based on the pool create parameters + * and will then set the actual length of the packet to 0. The result is + * the same as if the following sequence had been called by the application: + * @code + * pkt = odp_packet_alloc(pool, default_len); + * odp_packet_reset(pkt, 0); + * @endcode */ odp_packet_t odp_packet_alloc(odp_pool_t pool, uint32_t len);