diff mbox series

[API-NEXT,v14,4/8] linux-generic: queue: change order lock count data type

Message ID 1505469621-12939-5-git-send-email-odpbot@yandex.ru
State New
Headers show
Series [API-NEXT,v14,1/8] api: queue: change order lock count data type | expand

Commit Message

Github ODP bot Sept. 15, 2017, 10 a.m. UTC
From: Balasubramanian Manoharan <bala.manoharan@linaro.org>


change order lock count data type from unsigned to uint32_t

Signed-off-by: Balasubramanian Manoharan <bala.manoharan@linaro.org>

---
/** 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 mbox series

Patch

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,