From patchwork Fri Jun 16 11:21:34 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Balasubramanian Manoharan X-Patchwork-Id: 105712 Delivered-To: patch@linaro.org Received: by 10.140.91.77 with SMTP id y71csp1250836qgd; Fri, 16 Jun 2017 04:21:51 -0700 (PDT) X-Received: by 10.237.62.8 with SMTP id l8mr11832549qtf.20.1497612111750; Fri, 16 Jun 2017 04:21:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1497612111; cv=none; d=google.com; s=arc-20160816; b=u0WWxSWZ8G8Zz6dAmjshiKy0sNlJM4paZlEoqeEbk7yjcC8t3CeHXgoS+yx0n9hz0v EK/L5FKgzeG/I/+7yQepDW6+m7Ni/9MKzTxQUcYtYPOzmUNIwcPQDWzaVA7P6fCqFYV7 nzKMB0LM9GJgwDYTX23lLFNWYpa2M1mTA0DbZlCTUQqnyBPkjGfigXhQye3J3toGhSdx jhZrjuUnpWGgBt+C13DtI3hg46UaAD8eNcTaQVGbOcinFMsuClVw8farK6kv7X6mdBe4 odFHV0ALP270La9qmhg9+ypBjVUzRJOWswNxOoV9I4LkZIJFPlolS7Ea7/m231Ftf0Zv fjiQ== 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:message-id:date:to:from :delivered-to:arc-authentication-results; bh=hdKBUf0Ixdm8PeORHJmEXKFMhFtuoWDSaZor5zsV7SQ=; b=RP+IrnbyBr4K61Ak5wzqcE8Z2HdekpOoeT4ZQWiGit4a2sqP7VIGntr8c+nLQe8con ZyVuJvPC3QgS59ce9R5V7uB6pIMSuLdG52atlxH6T5Q2zGy5nL6Tx/ANIaU9dbn07V9P h+FP76gbAdyPYvU4KUIbB0jAsADWVU7dWUpCXe7axhIaJXTf6xC5ZjhOQVUk1d+p3tCn CP4C6+nzG2o8OWj6pXlsYUUkv1Sm1KwFRh63gJVECmBQvdTA25xkgUyv2F1pYNkVf+9c HaYVp8KVtpp/wc8/G5ObMl7mvrsVeA4HhS/xR7sVtiNZzwetizzpE/bxmmPnviA1n6c4 iFdw== 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id p37si1802639qtp.101.2017.06.16.04.21.51; Fri, 16 Jun 2017 04:21:51 -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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 3705260C0D; Fri, 16 Jun 2017 11:21:51 +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=-0.4 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, RCVD_IN_SORBS_WEB, 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 1DFAD6066C; Fri, 16 Jun 2017 11:21:47 +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 2344360672; Fri, 16 Jun 2017 11:21:45 +0000 (UTC) Received: from mail-pg0-f45.google.com (mail-pg0-f45.google.com [74.125.83.45]) by lists.linaro.org (Postfix) with ESMTPS id 466506065D for ; Fri, 16 Jun 2017 11:21:44 +0000 (UTC) Received: by mail-pg0-f45.google.com with SMTP id u62so42633pgb.3 for ; Fri, 16 Jun 2017 04:21:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=hdKBUf0Ixdm8PeORHJmEXKFMhFtuoWDSaZor5zsV7SQ=; b=tAyX7zE9W6xg0aT0V7tUAxZb1Do7xwodYRf7jU5BR5A6YVs032wtxA+XZ4ZswVDF/e wwKjg8VttN1utid/ZOLOhLXBnWt5g62oWy1DyKwX6aIw9rlNNH+JpptvQ+WcwhSp9Q0M BM0btmSdrqeKd0p8rM0wLEP/JXk/NU+tb5mZv59GRO+u29UASL04oThqoCk3XcSw6WJV /vDWOsB/FnTq9p4RpsKHtfTMuanF3hFfwmQCQmZCrgsTUKbf1rPF8JmdqXw4hC4Du5rQ iUMyNfMDpxQQHF+4TZpi9HDo1DWrg4txn7GYOsRoxSXaT9CnVxvpXFCTEWfJKFO4+aOJ mjhw== X-Gm-Message-State: AKS2vOy04HhZ/pP3/ZTs675jwdobuNNNGcR8Eo6x50+GEePMvZxyzRur NCslI0vcuCR6xKPT0GdvPr2m X-Received: by 10.101.69.207 with SMTP id m15mr10576023pgr.242.1497612103424; Fri, 16 Jun 2017 04:21:43 -0700 (PDT) Received: from bala-Vostro-2520.caveonetworks.com ([111.93.218.67]) by smtp.gmail.com with ESMTPSA id n2sm4575331pgd.26.2017.06.16.04.21.41 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 16 Jun 2017 04:21:42 -0700 (PDT) From: Balasubramanian Manoharan To: lng-odp@lists.linaro.org Date: Fri, 16 Jun 2017 16:51:34 +0530 Message-Id: <1497612094-5991-1-git-send-email-bala.manoharan@linaro.org> X-Mailer: git-send-email 1.9.1 Subject: [lng-odp] [RFC/API-NEXT] api: schedule: add ordered context unlock-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" Adds api to release an existing ordered lock and acquire a new lock. Signed-off-by: Balasubramanian Manoharan --- include/odp/api/spec/schedule.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) -- 1.7.9.5 diff --git a/include/odp/api/spec/schedule.h b/include/odp/api/spec/schedule.h index 8244746..c5d2214 100644 --- a/include/odp/api/spec/schedule.h +++ b/include/odp/api/spec/schedule.h @@ -368,6 +368,26 @@ void odp_schedule_order_lock(unsigned lock_index); void odp_schedule_order_unlock(unsigned lock_index); /** + * Release ordered context lock and acquires new lock + * + * This call is valid only when holding an ordered synchronization context. + * Release a previously locked ordered context lock and acquires + * a new ordered context lock. + * This call is valid only when there is a single ordered context lock and + * is invalid if there are nested ordered context lock. + * + * @param lock_index Index of the ordered lock in the current context to be + * acquired. Previously acquired ordered lock is released. + * Results are undefined if there is a nested ordered lock + * in the context. Must be in the range + * 0...odp_queue_lock_count() - 1 + * + * @see odp_schedule_order_lock(), odp_schedule_order_unlock() + * + */ +void odp_schedule_order_unlock_lock(uint32_t lock_index); + +/** * @} */