From patchwork Fri Sep 15 10: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: 112698 Delivered-To: patch@linaro.org Received: by 10.140.106.117 with SMTP id d108csp429304qgf; Fri, 15 Sep 2017 03:07:10 -0700 (PDT) X-Google-Smtp-Source: AOwi7QAz6pgBiL9vaeQTd/Tnj0uPyY50BE1HqvBMqo7T/kldMecQe/f+3olg960wHD3wEUd4FLq7 X-Received: by 10.55.4.141 with SMTP id 135mr6408293qke.86.1505470029994; Fri, 15 Sep 2017 03:07:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1505470029; cv=none; d=google.com; s=arc-20160816; b=xwo8Jcu2OCZBUVYeSA2YVQZUKIw4euMumnT8y8BLZ7wsbKcH8m+X2eTXNwzfmm0grJ 8gtNc7BJQYvdVCtY4WgF1ICTC28BzcVxD0IxcN3QPARhuxx7Yf82PFm4jYyT+adsgQAq 29mJ36mo184cErPBwH33j/OBbpBNHGkCXISZFvovXd0ZTtjwPMKvLl+F0D+LGL4pwhOV PVFuQC9wAF02nS4iyjRZxkFGhfF1L4JEiLxJ0jQJYnJR3DYliXSl9G41D/6hf2bAlbsz K34qYI/NQepVUfTYKmH0y55n/vxxa5xHJVS2ds7nqasw9t+oi3cpoR4CtPRNX8YGu7uD V14Q== 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=9kskm//Ive/mRtv8b848Qt3HFLrH/g8GC89+Quiy1is=; b=TecyYo8VkKxnYUbRTzGFDdE+mNjPWZZz63xAoSdvSsGKSqJjlY3p2Dc2V/OoM09SA6 UZso09jQSiC4EH7ApfN9Z6UXwI+Q3Bs6lWw0Wu1duxwsFWsC7VLxuMdk+/6qLbQaH0Rb icZ36zx3BdyEDpZqLTG5ANLtZ6At66QFoS6KftwhjRHK4bHon0ouQX0K2KicPQQnkjEP xXc/Rl77Du1i+xnAG4uUzjrAlCYT3jvy5RMvUQtJ2jFcNAQDvlEObhmTkGAFLCMgUD8w ayaHM/JwUc0x4yWlwS7/1tMb+QJkOy+WRJTswE7VPNdhPTd41nKT3sQc0sdqUvQTDW41 Yx2Q== 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 92si572051qkx.463.2017.09.15.03.07.09; Fri, 15 Sep 2017 03:07:09 -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 A9E5E60988; Fri, 15 Sep 2017 10:07:09 +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 39414609D6; Fri, 15 Sep 2017 10:02:07 +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 EE380609D6; Fri, 15 Sep 2017 10:01:58 +0000 (UTC) Received: from forward104p.mail.yandex.net (forward104p.mail.yandex.net [77.88.28.107]) by lists.linaro.org (Postfix) with ESMTPS id 58D41609DA for ; Fri, 15 Sep 2017 10:00:37 +0000 (UTC) Received: from mxback3o.mail.yandex.net (mxback3o.mail.yandex.net [IPv6:2a02:6b8:0:1a2d::1d]) by forward104p.mail.yandex.net (Yandex) with ESMTP id B2926182EFC for ; Fri, 15 Sep 2017 13:00:34 +0300 (MSK) Received: from smtp2j.mail.yandex.net (smtp2j.mail.yandex.net [2a02:6b8:0:801::ac]) by mxback3o.mail.yandex.net (nwsmtp/Yandex) with ESMTP id 7hM2NCZLS4-0YVSgHKu; Fri, 15 Sep 2017 13:00:34 +0300 Received: by smtp2j.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id clr2IsS8eV-0YTmrISG; Fri, 15 Sep 2017 13:00:34 +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: Fri, 15 Sep 2017 13:00:17 +0300 Message-Id: <1505469621-12939-5-git-send-email-odpbot@yandex.ru> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1505469621-12939-1-git-send-email-odpbot@yandex.ru> References: <1505469621-12939-1-git-send-email-odpbot@yandex.ru> Github-pr-num: 160 Subject: [lng-odp] [PATCH API-NEXT v14 4/8] linux-generic: queue: change order lock count data type 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 change order lock count data type 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: 236aa5fbfddcbccd5bf62c87fea274b272bfec72 **/ platform/linux-generic/include/odp_queue_if.h | 2 +- platform/linux-generic/odp_queue.c | 4 ++-- platform/linux-generic/odp_queue_if.c | 2 +- platform/linux-generic/odp_queue_scalable.c | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/platform/linux-generic/include/odp_queue_if.h b/platform/linux-generic/include/odp_queue_if.h index 410c6b796..ed8d6ca99 100644 --- a/platform/linux-generic/include/odp_queue_if.h +++ b/platform/linux-generic/include/odp_queue_if.h @@ -38,7 +38,7 @@ typedef struct { odp_schedule_sync_t (*queue_sched_type)(odp_queue_t queue); odp_schedule_prio_t (*queue_sched_prio)(odp_queue_t queue); odp_schedule_group_t (*queue_sched_group)(odp_queue_t queue); - int (*queue_lock_count)(odp_queue_t queue); + uint32_t (*queue_lock_count)(odp_queue_t queue); uint64_t (*queue_to_u64)(odp_queue_t hdl); void (*queue_param_init)(odp_queue_param_t *param); int (*queue_info)(odp_queue_t queue, odp_queue_info_t *info); diff --git a/platform/linux-generic/odp_queue.c b/platform/linux-generic/odp_queue.c index d941accc2..3f355e695 100644 --- a/platform/linux-generic/odp_queue.c +++ b/platform/linux-generic/odp_queue.c @@ -175,12 +175,12 @@ static odp_schedule_group_t queue_sched_group(odp_queue_t handle) return handle_to_qentry(handle)->s.param.sched.group; } -static int queue_lock_count(odp_queue_t handle) +static uint32_t queue_lock_count(odp_queue_t handle) { queue_entry_t *queue = handle_to_qentry(handle); return queue->s.param.sched.sync == ODP_SCHED_SYNC_ORDERED ? - (int)queue->s.param.sched.lock_count : -1; + queue->s.param.sched.lock_count : 0; } static odp_queue_t queue_create(const char *name, diff --git a/platform/linux-generic/odp_queue_if.c b/platform/linux-generic/odp_queue_if.c index 44fda0d68..969b0d3cb 100644 --- a/platform/linux-generic/odp_queue_if.c +++ b/platform/linux-generic/odp_queue_if.c @@ -92,7 +92,7 @@ odp_schedule_group_t odp_queue_sched_group(odp_queue_t queue) return queue_api->queue_sched_group(queue); } -int odp_queue_lock_count(odp_queue_t queue) +uint32_t odp_queue_lock_count(odp_queue_t queue) { return queue_api->queue_lock_count(queue); } diff --git a/platform/linux-generic/odp_queue_scalable.c b/platform/linux-generic/odp_queue_scalable.c index bcda21953..b6275eb70 100644 --- a/platform/linux-generic/odp_queue_scalable.c +++ b/platform/linux-generic/odp_queue_scalable.c @@ -333,12 +333,12 @@ static odp_schedule_group_t queue_sched_group(odp_queue_t handle) return qentry_from_int(queue_from_ext(handle))->s.param.sched.group; } -static int queue_lock_count(odp_queue_t handle) +static uint32_t queue_lock_count(odp_queue_t handle) { queue_entry_t *queue = qentry_from_int(queue_from_ext(handle)); return queue->s.param.sched.sync == ODP_SCHED_SYNC_ORDERED ? - (int)queue->s.param.sched.lock_count : -1; + queue->s.param.sched.lock_count : 0; } static odp_queue_t queue_create(const char *name,