From patchwork Sun Sep 6 02:50:21 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bill Fischofer X-Patchwork-Id: 53158 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f71.google.com (mail-la0-f71.google.com [209.85.215.71]) by patches.linaro.org (Postfix) with ESMTPS id 29D3520A78 for ; Sun, 6 Sep 2015 02:51:42 +0000 (UTC) Received: by laeb10 with SMTP id b10sf18183430lae.1 for ; Sat, 05 Sep 2015 19:51:40 -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:in-reply-to:references: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=7562nqB52tkI+X2FZPFvwmTxzExWu/O40Jb/kW6Z9uQ=; b=c9rbK30tUG+Em0BSEAXTAryloYbI076Uxdd71hl+AUDlSjz7FndXvFi4pEykgVG8PM lsF8Z9ymNzmryNRyCDcItT28f9V9Vxp8gq0swWT5ek5asCKvwP4/U24UXxNVeF6RgNfH n9u72Xwy36YG2lFqw0+lpMFVNG/dceIQlRtMSM5F0PiQjRf9eutKD24L0+xteLwl70YC vHCJqbb3xSJIwFKsHAzuAVDWmFG+ekHzaCI8hiT910MX3n9qYRJ6x9FO6lUdzAsTXukd BWWVDtv3EU4i59TylUrptDMPb+aNBJpYmBJW+N84sPhtNv0TU/ZAvuRplnmhAymS1gxJ 0T4g== X-Gm-Message-State: ALoCoQmF15UbBlrxfBOPk2Ht81iS3wiyEHoBm7JluV+sSiW4BQb+g+olgN8yP2E8S4tZ7UG7CmiP X-Received: by 10.180.90.106 with SMTP id bv10mr3164263wib.6.1441507900721; Sat, 05 Sep 2015 19:51:40 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.239.161 with SMTP id vt1ls399606lac.41.gmail; Sat, 05 Sep 2015 19:51:40 -0700 (PDT) X-Received: by 10.112.161.40 with SMTP id xp8mr10873641lbb.71.1441507900429; Sat, 05 Sep 2015 19:51:40 -0700 (PDT) Received: from mail-la0-f44.google.com (mail-la0-f44.google.com. [209.85.215.44]) by mx.google.com with ESMTPS id yh4si6774411lab.144.2015.09.05.19.51.40 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 05 Sep 2015 19:51:40 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.44 as permitted sender) client-ip=209.85.215.44; Received: by lagj9 with SMTP id j9so34212001lag.2 for ; Sat, 05 Sep 2015 19:51:40 -0700 (PDT) X-Received: by 10.152.170.230 with SMTP id ap6mr10976730lac.73.1441507899979; Sat, 05 Sep 2015 19:51:39 -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.164.42 with SMTP id yn10csp772017lbb; Sat, 5 Sep 2015 19:51:39 -0700 (PDT) X-Received: by 10.50.79.196 with SMTP id l4mr19419424igx.48.1441507899116; Sat, 05 Sep 2015 19:51:39 -0700 (PDT) Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id 39si1825149iop.174.2015.09.05.19.51.38; Sat, 05 Sep 2015 19:51:39 -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 0A95361CAB; Sun, 6 Sep 2015 02:51:38 +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, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, 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 200CC61CCC; Sun, 6 Sep 2015 02:50:39 +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 C4A3A618C9; Sun, 6 Sep 2015 02:50:32 +0000 (UTC) Received: from mail-ob0-f180.google.com (mail-ob0-f180.google.com [209.85.214.180]) by lists.linaro.org (Postfix) with ESMTPS id A6576618C9 for ; Sun, 6 Sep 2015 02:50:31 +0000 (UTC) Received: by obbbh8 with SMTP id bh8so42081134obb.0 for ; Sat, 05 Sep 2015 19:50:31 -0700 (PDT) X-Received: by 10.60.63.41 with SMTP id d9mr9447728oes.17.1441507831172; Sat, 05 Sep 2015 19:50:31 -0700 (PDT) Received: from Ubuntu15.localdomain (cpe-24-28-70-239.austin.res.rr.com. [24.28.70.239]) by smtp.gmail.com with ESMTPSA id k187sm4558263oia.18.2015.09.05.19.50.30 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 05 Sep 2015 19:50:30 -0700 (PDT) From: Bill Fischofer To: lng-odp@lists.linaro.org Date: Sat, 5 Sep 2015 21:50:21 -0500 Message-Id: <1441507824-16437-3-git-send-email-bill.fischofer@linaro.org> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1441507824-16437-1-git-send-email-bill.fischofer@linaro.org> References: <1441507824-16437-1-git-send-email-bill.fischofer@linaro.org> X-Topics: patch Subject: [lng-odp] [API-NEXT PATCH 2/5] api: queue: add odp_queue_lock_count() API 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.44 as permitted sender) smtp.mailfrom=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 --- include/odp/api/queue.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/include/odp/api/queue.h b/include/odp/api/queue.h index ce04eb4..56afcbf 100644 --- a/include/odp/api/queue.h +++ b/include/odp/api/queue.h @@ -245,6 +245,18 @@ odp_schedule_prio_t odp_queue_sched_prio(odp_queue_t queue); odp_schedule_group_t odp_queue_sched_group(odp_queue_t queue); /** + * Queue lock count + * + * @note Passing an invalid queue_handle will result in UNDEFINED behavior + * + * @param queue Queue handle + * + * @return Number of ordered locks associated with this ordered queue + * @retval 0 Queue is not ordered or was not created with ordered locks + */ +uint32_t odp_queue_lock_count(odp_queue_t queue); + +/** * Get printable value for an odp_queue_t * * @param hdl odp_queue_t handle to be printed