From patchwork Thu Jan 29 10:40:03 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ola Liljedahl X-Patchwork-Id: 43912 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wi0-f197.google.com (mail-wi0-f197.google.com [209.85.212.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 74E6A24119 for ; Thu, 29 Jan 2015 10:41:38 +0000 (UTC) Received: by mail-wi0-f197.google.com with SMTP id n3sf11426206wiv.0 for ; Thu, 29 Jan 2015 02:41:37 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state: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=JopatMrgR9GsK87fchL8f/j0fawcSWhj8+qBxz/K0vI=; b=YPY7KlNtBtcvhBhbIKT01qy2OB/TqwKtVfKIGoUZ8KIRHmu57zNDlD44NC4m7X2vHf LStRuo9NF6qUtCroStjNtkxqn2wwIM/njLX06BYEJUdiNvculm5skcJatllo7AP6byhP 9Uj/wrGTMJVZ+VdKsPUJYhM+8euBYuM+9r8JViVNKwk/3KJ3CQ4SNk4Vzrj7fFEBY553 OWJQY3dtz6FmB7mqN6a0gV8p+CXTQDg6EL3EtB6EEVZMWMlwL8+Q4xuXhc9UXIYN3pJg U7iposNgdt6Psg703GFhJvkQou6zQhAymKzmblkEl8PQ8rEmls8vAvsNOEKbaIzT5LvA gmUg== X-Gm-Message-State: ALoCoQmVyDKmqUnCe6aVtKCZv7EZI7KHQ0r32uLfq9TmrSpgUj7tuN1fgd3AeoDlqX4TSlI7cogH X-Received: by 10.180.88.66 with SMTP id be2mr228232wib.1.1422528097728; Thu, 29 Jan 2015 02:41:37 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.88.99 with SMTP id bf3ls285353lab.13.gmail; Thu, 29 Jan 2015 02:41:37 -0800 (PST) X-Received: by 10.152.42.164 with SMTP id p4mr13445713lal.45.1422528097568; Thu, 29 Jan 2015 02:41:37 -0800 (PST) Received: from mail-lb0-f181.google.com (mail-lb0-f181.google.com. [209.85.217.181]) by mx.google.com with ESMTPS id de6si3056651lac.24.2015.01.29.02.41.37 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 29 Jan 2015 02:41:37 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.181 as permitted sender) client-ip=209.85.217.181; Received: by mail-lb0-f181.google.com with SMTP id u10so26561396lbd.12 for ; Thu, 29 Jan 2015 02:41:37 -0800 (PST) X-Received: by 10.152.6.132 with SMTP id b4mr13576984laa.59.1422528097185; Thu, 29 Jan 2015 02:41:37 -0800 (PST) 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.35.133 with SMTP id h5csp1719630lbj; Thu, 29 Jan 2015 02:41:36 -0800 (PST) X-Received: by 10.140.44.34 with SMTP id f31mr10718qga.3.1422528095621; Thu, 29 Jan 2015 02:41:35 -0800 (PST) Received: from ip-10-35-177-41.ec2.internal (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTPS id b53si9695749qge.89.2015.01.29.02.41.34 (version=TLSv1 cipher=RC4-SHA bits=128/128); Thu, 29 Jan 2015 02:41:35 -0800 (PST) Received-SPF: none (google.com: lng-odp-bounces@lists.linaro.org does not designate permitted sender hosts) client-ip=54.225.227.206; Received: from localhost ([127.0.0.1] helo=ip-10-35-177-41.ec2.internal) by ip-10-35-177-41.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1YGmXU-0007RT-PE; Thu, 29 Jan 2015 10:41:32 +0000 Received: from mail-lb0-f176.google.com ([209.85.217.176]) by ip-10-35-177-41.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1YGmWR-0007JB-H3 for lng-odp@lists.linaro.org; Thu, 29 Jan 2015 10:40:27 +0000 Received: by mail-lb0-f176.google.com with SMTP id z12so26507795lbi.7 for ; Thu, 29 Jan 2015 02:40:22 -0800 (PST) X-Received: by 10.112.12.134 with SMTP id y6mr13533003lbb.34.1422528021971; Thu, 29 Jan 2015 02:40:21 -0800 (PST) Received: from macmini.lan (78-82-118-111.tn.glocalnet.net. [78.82.118.111]) by mx.google.com with ESMTPSA id y11sm2037670lba.5.2015.01.29.02.40.20 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 29 Jan 2015 02:40:21 -0800 (PST) From: Ola Liljedahl To: lng-odp@lists.linaro.org Date: Thu, 29 Jan 2015 11:40:03 +0100 Message-Id: <1422528008-29845-12-git-send-email-ola.liljedahl@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1422528008-29845-1-git-send-email-ola.liljedahl@linaro.org> References: <1422528008-29845-1-git-send-email-ola.liljedahl@linaro.org> X-Topics: patch Subject: [lng-odp] [PATCH 11/16] api: odp_queue.h: updated return descriptions X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.14 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-bounces@lists.linaro.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: ola.liljedahl@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.217.181 as permitted sender) smtp.mail=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 Updated doxygen descriptions, particularly the @return/@retval descriptions. No change of implementation necessary. Signed-off-by: Ola Liljedahl --- (This document/code contribution attached is provided under the terms of agreement LES-LTM-21309) platform/linux-generic/include/api/odp_queue.h | 29 ++++++++++++++++---------- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/platform/linux-generic/include/api/odp_queue.h b/platform/linux-generic/include/api/odp_queue.h index fceed4d..79c7e80 100644 --- a/platform/linux-generic/include/api/odp_queue.h +++ b/platform/linux-generic/include/api/odp_queue.h @@ -118,7 +118,8 @@ typedef struct odp_queue_param_t { * @param type Queue type * @param param Queue parameters. Uses defaults if NULL. * - * @return Queue handle or ODP_QUEUE_INVALID + * @return Queue handle + * @retval ODP_QUEUE_INVALID on failure */ odp_queue_t odp_queue_create(const char *name, odp_queue_type_t type, odp_queue_param_t *param); @@ -133,7 +134,8 @@ odp_queue_t odp_queue_create(const char *name, odp_queue_type_t type, * * @param queue Queue handle * - * @return 0 if successful + * @retval 0 on success + * @retval <0 on failure */ int odp_queue_destroy(odp_queue_t queue); @@ -142,7 +144,8 @@ int odp_queue_destroy(odp_queue_t queue); * * @param name Queue name * - * @return Queue handle or ODP_QUEUE_INVALID + * @return Queue handle + * @retval ODP_QUEUE_INVALID on failure */ odp_queue_t odp_queue_lookup(const char *name); @@ -156,7 +159,8 @@ odp_queue_t odp_queue_lookup(const char *name); * @param queue Queue handle * @param context Address to the queue context * - * @return 0 if successful + * @retval 0 on success + * @retval <0 on failure */ int odp_queue_set_context(odp_queue_t queue, void *context); @@ -165,8 +169,8 @@ int odp_queue_set_context(odp_queue_t queue, void *context); * * @param queue Queue handle * - * @return If successful, a pointer to the queue context, - * NULL for failure. + * @return pointer to the queue context + * @retval NULL on failure */ void *odp_queue_get_context(odp_queue_t queue); @@ -176,7 +180,8 @@ void *odp_queue_get_context(odp_queue_t queue); * @param queue Queue handle * @param ev Event handle * - * @return 0 if succesful + * @retval 0 on success + * @retval <0 on failure (e.g. queue full) */ int odp_queue_enq(odp_queue_t queue, odp_event_t ev); @@ -199,7 +204,8 @@ int odp_queue_enq_multi(odp_queue_t queue, odp_event_t ev[], int num); * * @param queue Queue handle * - * @return Event handle, or ODP_EVENT_INVALID + * @return Event handle + * @retval ODP_EVENT_INVALID on failure (e.g. queue empty) */ odp_event_t odp_queue_deq(odp_queue_t queue); @@ -210,10 +216,11 @@ odp_event_t odp_queue_deq(odp_queue_t queue); * ODP_QUEUE_TYPE_SCHED type queues (use odp_schedule() instead). * * @param queue Queue handle - * @param events Event handle array for output - * @param num Maximum number of event handles + * @param[out] events Array of event handles for output + * @param num Maximum number of events to dequeue - * @return Number of events written (0 ... num) + * @return Number of events actually dequeued (0 ... num) + * @retval <0 on failure */ int odp_queue_deq_multi(odp_queue_t queue, odp_event_t events[], int num);