From patchwork Thu Sep 14 15:00:07 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: 112569 Delivered-To: patch@linaro.org Received: by 10.140.106.117 with SMTP id d108csp850244qgf; Thu, 14 Sep 2017 08:08:33 -0700 (PDT) X-Google-Smtp-Source: AOwi7QDKX30+1ZBq3MRKp/LwqssExXFv5RBP4KcFFrt7F8IlfU5Af6EZTS76/v/jdDvklGjj4qNv X-Received: by 10.200.47.114 with SMTP id k47mr33458210qta.109.1505401713651; Thu, 14 Sep 2017 08:08:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1505401713; cv=none; d=google.com; s=arc-20160816; b=dTuLJ0vH+ZccX7pFwflyhy4aYPCPmKSNNc5gfiIbbjv+BiGFINtJi2KREGLI+EiVb0 MudIX9nDpNaBY14WTyfXkv0VvJ+1wqljxJ61RYGZPvhvO0uv5tkgkxdToouQMy/5AgqL L1wTKVVQBdZH2dCpe88VsF6PRbjCox6VWWlhiFEPBgqNOdznJT0fF72YNFWxqSL5W5PK bDMQDxV1K7O8UQgU3pSCSligYdu+ye3rq5ogp/7Xr33skw0Wz0YzfF0gV4YSLL3t3WrA cMlNIOERSsjpreMUbTMutP+6Bz8ME2SgixlEqYsUddBm3PMerUx9dAxUZV7zs762RfgY YErw== 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=LaKLB9YSYD0rHDo7PqBlkBA2SBPDdo/gtk+BcvrRSyY=; b=SMdOeEC5uPPkdYedFS7XLsZzeVKmwN86TKSaaE/2vfbCv+zflZYNb2ZMlN1fhHfcuX 6oXx738q+hYzDxlDogXPNP4Z/1FgWtTwlvuHv18K5GxW08n7/8uM6n3SluhcxmpIxDTA wd9LT0MeJEOLmgmM62qUQQr6geKucKSSZpWP2ifA4KBVLoGDTPXgxlHbna4SGR8uSxew md79yKhLREMXq65w1DwFpUnkuN+KzIdebeMQAXf7gRHnjbB6RcmOvLbmsE4SgCBKRZOO eaOyKHB/C0FVKFnCk4fujKbCCfxUj0IY+7TF/DJv6IljabM+fWBD6oCpCLC2BbQkWG3O x+WA== 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 i6si17073020qkc.424.2017.09.14.08.08.33; Thu, 14 Sep 2017 08:08:33 -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 00B5460BE9; Thu, 14 Sep 2017 15:08:32 +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=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,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 BA28F60639; Thu, 14 Sep 2017 15:01:18 +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 1CF9B6097C; Thu, 14 Sep 2017 15:00:33 +0000 (UTC) Received: from forward106j.mail.yandex.net (forward106j.mail.yandex.net [5.45.198.249]) by lists.linaro.org (Postfix) with ESMTPS id 15A34608E0 for ; Thu, 14 Sep 2017 15:00:25 +0000 (UTC) Received: from mxback7j.mail.yandex.net (mxback7j.mail.yandex.net [IPv6:2a02:6b8:0:1619::110]) by forward106j.mail.yandex.net (Yandex) with ESMTP id 63D641803E6C for ; Thu, 14 Sep 2017 18:00:23 +0300 (MSK) Received: from smtp3o.mail.yandex.net (smtp3o.mail.yandex.net [2a02:6b8:0:1a2d::27]) by mxback7j.mail.yandex.net (nwsmtp/Yandex) with ESMTP id I83ZuA0LMN-0NAKFiae; Thu, 14 Sep 2017 18:00:23 +0300 Received: by smtp3o.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id gNZkqRzw9k-0M7Kkrx6; Thu, 14 Sep 2017 18:00:22 +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: Thu, 14 Sep 2017 18:00:07 +0300 Message-Id: <1505401213-7265-7-git-send-email-odpbot@yandex.ru> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1505401213-7265-1-git-send-email-odpbot@yandex.ru> References: <1505401213-7265-1-git-send-email-odpbot@yandex.ru> Github-pr-num: 160 Subject: [lng-odp] [PATCH API-NEXT v11 6/12] api: schedule: remove support for nested ordered lock 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 removes support for nested ordered lock use-case changes function param signature from unsigned to uint32_t Signed-off-by: Balasubramanian Manoharan --- /** Email created from pull request 160 (bala-manoharan:api_sched_order_lock) ** https://github.com/Linaro/odp/pull/160 ** Patch: https://github.com/Linaro/odp/pull/160.patch ** Base sha: 6b6253c30f88c80bf632436ff06c1b000860a2f1 ** Merge commit sha: 438a3bab5df9c05dc06f0b4e4b22c0a7db0864fd **/ include/odp/api/spec/schedule.h | 7 +++++-- include/odp/api/spec/schedule_types.h | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/include/odp/api/spec/schedule.h b/include/odp/api/spec/schedule.h index 8244746d7..e2abf990b 100644 --- a/include/odp/api/spec/schedule.h +++ b/include/odp/api/spec/schedule.h @@ -347,12 +347,15 @@ int odp_schedule_group_info(odp_schedule_group_t group, * be protected by its own ordered lock. This promotes maximum parallelism by * allowing order to maintained on a more granular basis. If an ordered lock * is used multiple times in the same ordered context results are undefined. + * Only one ordered lock can be active in an ordered context at any given time. + * Results are undefined when multiple ordered locks are acquired in nested + * fashion within the same ordered context. * * @param lock_index Index of the ordered lock in the current context to be * acquired. Must be in the range 0..odp_queue_lock_count() * - 1 */ -void odp_schedule_order_lock(unsigned lock_index); +void odp_schedule_order_lock(uint32_t lock_index); /** * Release ordered context lock @@ -365,7 +368,7 @@ void odp_schedule_order_lock(unsigned lock_index); * hold this lock. Must be in the range * 0..odp_queue_lock_count() - 1 */ -void odp_schedule_order_unlock(unsigned lock_index); +void odp_schedule_order_unlock(uint32_t lock_index); /** * @} diff --git a/include/odp/api/spec/schedule_types.h b/include/odp/api/spec/schedule_types.h index 8a4e42c64..397f98fcd 100644 --- a/include/odp/api/spec/schedule_types.h +++ b/include/odp/api/spec/schedule_types.h @@ -146,7 +146,7 @@ typedef struct odp_schedule_param_t { /** Ordered lock count for this queue * * Default value is 0. */ - unsigned lock_count; + uint32_t lock_count; } odp_schedule_param_t; /**