Hello Jose,
patch should have prefix "API-NEXT" and short log starts with "api:"
CC, Petri to review this patch. I think we need more explanation about
usage in doxygen comment than in git log.
Maxim.
On 02/22/16 15:39, José Pekkarinen wrote:
To provide support of different definitions of odp_queue_t
it's required to have a proper mechanism to set the queue
invalid in case any error during the transmission happen.
This eases the case when odp_queue_t is defined as an union
and the type of this queue is set as a member of the given
union.
Signed-off-by: José Pekkarinen <jose.pekkari...@nokia.com>
---
include/odp/api/queue.h | 10 ++++++++++
platform/linux-generic/odp_queue.c | 10 ++++++++++
2 files changed, 20 insertions(+)
diff --git a/include/odp/api/queue.h b/include/odp/api/queue.h
index bde8ca3..95eaf3b 100644
--- a/include/odp/api/queue.h
+++ b/include/odp/api/queue.h
@@ -371,6 +371,16 @@ typedef struct odp_queue_info_t {
int odp_queue_info(odp_queue_t queue, odp_queue_info_t *info);
/**
+ * Invalidate a queue
+ *
+ * @param queue Queue handle
+ *
+ * @retval 0 Success
+ * @retval <0 Failure. Queue could not be invalidated.
+ */
+int odp_queue_invalidate(odp_queue_t queue);
+
+/**
* @}
*/
diff --git a/platform/linux-generic/odp_queue.c b/platform/linux-generic/odp_queue.c
index dbe2d9c..e105eee 100644
--- a/platform/linux-generic/odp_queue.c
+++ b/platform/linux-generic/odp_queue.c
@@ -1116,3 +1116,13 @@ int odp_queue_info(odp_queue_t handle, odp_queue_info_t
*info)
return 0;
}
+
+int odp_queue_invalidate(odp_queue_t handle)
+{
+ if((handle = ODP_QUEUE_INVALID)){
+ ODP_ERR("Queue could not be invalidated\n");
+ return -1;
+ }
+
+ return 0;
+}
_______________________________________________
lng-odp mailing list
lng-odp@lists.linaro.org
https://lists.linaro.org/mailman/listinfo/lng-odp