diff mbox

[PATCHv5,03/19] api: crypto: add strong typing handle display functions

Message ID 1422938699-12877-4-git-send-email-bill.fischofer@linaro.org
State Accepted
Commit 89c39b07bdc56e5679e21c5de9a78b69d0465a29
Headers show

Commit Message

Bill Fischofer Feb. 3, 2015, 4:44 a.m. UTC
Add functions odp_crypto_session_to_u64() and odp_crypto_compl_to_u64()

Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
---
 include/odp/api/crypto.h | 26 ++++++++++++++++++++++++++
 1 file changed, 26 insertions(+)
diff mbox

Patch

diff --git a/include/odp/api/crypto.h b/include/odp/api/crypto.h
index 545c1a5..03bf5fd 100644
--- a/include/odp/api/crypto.h
+++ b/include/odp/api/crypto.h
@@ -344,6 +344,32 @@  int
 odp_hw_random_get(uint8_t *buf, size_t *len, odp_bool_t use_entropy);
 
 /**
+ * Get printable value for an odp_crypto_session_t
+ *
+ * @param hdl  odp_crypto_session_t handle to be printed
+ * @return     uint64_t value that can be used to print/display this
+ *             handle
+ *
+ * @note This routine is intended to be used for diagnostic purposes
+ * to enable applications to generate a printable value that represents
+ * an odp_crypto_session_t handle.
+ */
+uint64_t odp_crypto_session_to_u64(odp_crypto_session_t hdl);
+
+/**
+ * Get printable value for an odp_crypto_compl_t
+ *
+ * @param hdl  odp_crypto_compl_t handle to be printed
+ * @return     uint64_t value that can be used to print/display this
+ *             handle
+ *
+ * @note This routine is intended to be used for diagnostic purposes
+ * to enable applications to generate a printable value that represents
+ * an odp_crypto_compl_t handle.
+ */
+uint64_t odp_crypto_compl_to_u64(odp_crypto_compl_t hdl);
+
+/**
  * @}
  */