From patchwork Mon Sep 4 13:00:17 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: 111594 Delivered-To: patch@linaro.org Received: by 10.140.94.166 with SMTP id g35csp1511360qge; Mon, 4 Sep 2017 06:10:30 -0700 (PDT) X-Google-Smtp-Source: ADKCNb4iLnUyjXBvWTyuOtpkg4a4X160VQfayYcMwKgRAI7hXCquy5gu4qrOyWJGBf/oq79iHmyS X-Received: by 10.55.161.85 with SMTP id k82mr753454qke.156.1504530630592; Mon, 04 Sep 2017 06:10:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1504530630; cv=none; d=google.com; s=arc-20160816; b=SqKqua5w2JCuihEkYpPOYU9eS8oSt1XMjgJfAt2sUKnOMLHVQR2TJYlJ9neD1PfqbE 5w2JCaNqo2tCHA1xSNzIbC/XHxh23RgbOpGsAQnqys6IyTPPN2KJ9/z0TUo9UpcNqIff sameZsk+pPNnXkfHQU3AQGnQI9HLBcnreoWBHpJN21v5aK5Cidi0ubtX3RKHxBWsA8M2 UDztfgzr+ePq3HTJBU7CUXNj2N27n9CED0lXcdaZyVF68rdiV9pWVnQsX3KQaTs1BW5y iDYGeX3KIQ5es1Q45TwQRCj1c2WcHVhG6C4YikCcFG0w7DOE7JlA4d0/1XnoyaBuqsTb 8qvA== 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=AstvaVMw7fOPZDHWhdN/CL4WNxdQpfC56Fn6qjzVR/Q=; b=y6LNwDsmTiKQbh1/gCn9yvSo+P8Z72lgq6DvefI8ZHOyXxNE5hZMJli+trCIfticHW hbM+wPmRt4/txRc/Z9NpGMiiC+eHKh09SupQ7zKIm/TonTtAeWIK1t5D28ZsUn9b1JIn zU8IQsm34HxKbSb8NnLT9n/wBkZMc4SUrKEFGsnoUhkZu08Y+naNB14FLyo7Iu1HedbJ sMI3vtu8I7q/Ft3dUrBna3LPq2jwygG6sQYD3woUT4yuISPqdOjiiA6g9diS+9EEyfr7 Y9E/UGchRb66Sy+wO8OHA9N+u5QuU84VX5kPdFZ1YvQMz5XRjfoSe1rN2esnxLPTpOyU F93w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 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 (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id h83si6185752qkh.311.2017.09.04.06.10.30; Mon, 04 Sep 2017 06:10: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; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 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 3393260C2C; Mon, 4 Sep 2017 13:10:30 +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=-2.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_LOW,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 91C0760C56; Mon, 4 Sep 2017 13:05:51 +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 50F1160D4B; Mon, 4 Sep 2017 13:05:40 +0000 (UTC) Received: from forward2j.cmail.yandex.net (forward2j.cmail.yandex.net [5.255.227.20]) by lists.linaro.org (Postfix) with ESMTPS id 7B5C860C8B for ; Mon, 4 Sep 2017 13:00:23 +0000 (UTC) Received: from smtp2o.mail.yandex.net (smtp2o.mail.yandex.net [37.140.190.27]) by forward2j.cmail.yandex.net (Yandex) with ESMTP id 1F14821066 for ; Mon, 4 Sep 2017 16:00:22 +0300 (MSK) Received: from smtp2o.mail.yandex.net (localhost.localdomain [127.0.0.1]) by smtp2o.mail.yandex.net (Yandex) with ESMTP id D75125080F18 for ; Mon, 4 Sep 2017 16:00:21 +0300 (MSK) Received: by smtp2o.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id f8326gO6zI-0KFOBTOU; Mon, 04 Sep 2017 16:00:20 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (Client certificate not present) X-Yandex-Suid-Status: 1 0 From: Github ODP bot To: lng-odp@lists.linaro.org Date: Mon, 4 Sep 2017 16:00:17 +0300 Message-Id: <1504530018-8522-2-git-send-email-odpbot@yandex.ru> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1504530018-8522-1-git-send-email-odpbot@yandex.ru> References: <1504530018-8522-1-git-send-email-odpbot@yandex.ru> Github-pr-num: 152 Subject: [lng-odp] [PATCH API-NEXT v4 1/2] api: pool: add min and max headroom in capability 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: Balasubramanian Manoharan Adds pool minimum and maximum headroom in pool capability Signed-off-by: Balasubramanian Manoharan --- /** Email created from pull request 152 (bala-manoharan:pool_headroom) ** https://github.com/Linaro/odp/pull/152 ** Patch: https://github.com/Linaro/odp/pull/152.patch ** Base sha: 91c0b58fc87ba0431241818758cea94438cd5498 ** Merge commit sha: e06c8842c41c8550928bb58c658116fb7c2f338b **/ include/odp/api/spec/pool.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/include/odp/api/spec/pool.h b/include/odp/api/spec/pool.h index 6fc5b6b4..6fe50620 100644 --- a/include/odp/api/spec/pool.h +++ b/include/odp/api/spec/pool.h @@ -97,6 +97,14 @@ typedef struct odp_pool_capability_t { * packet input and user allocated packets.*/ uint32_t min_headroom; + /** Maximum packet level headroom length in bytes + * + * This is the maximum value for packet pool headroom that + * can be configured. This value could be rounded up by the + * implimenation and it applies to both ODP packet input and + * user allocated packets.*/ + uint32_t max_headroom; + /** Minimum packet level tailroom length in bytes * * The minimum number of tailroom bytes that newly created @@ -214,6 +222,18 @@ typedef struct odp_pool_param_t { defined by pool capability pkt.max_uarea_size. Specify as 0 if no user area is needed. */ uint32_t uarea_size; + + /** Minimum Headroom size in bytes. Minimum number of + bytes of space preceding packet data to reserve for + use as headroom. Each newly allocated packet from + the pool must have at least this much headroom. + Must not exceed the implementation defined + 'max_headroom' in odp_pool_capability(). + @note if application does not required headroom it + may set min_headroom to zero and implementation may + set headroom as zero or roundup to minimum headroom + possible in the platform. */ + uint32_t min_headroom; } pkt; /** Parameters for timeout pools */