Merged!
Thanks,
Maxim.
On 11/07/2014 12:27 AM, Mike Holmes wrote:
Signed-off-by: Mike Holmes <mike.hol...@linaro.org>
---
platform/linux-generic/include/api/odp_shared_memory.h | 13 +++++++++++++
platform/linux-generic/odp_shared_memory.c | 6 ++++++
2 files changed, 19 insertions(+)
diff --git a/platform/linux-generic/include/api/odp_shared_memory.h
b/platform/linux-generic/include/api/odp_shared_memory.h
index d8d40dd..1a59824 100644
--- a/platform/linux-generic/include/api/odp_shared_memory.h
+++ b/platform/linux-generic/include/api/odp_shared_memory.h
@@ -72,6 +72,19 @@ odp_shm_t odp_shm_reserve(const char *name, uint64_t size,
uint64_t align,
uint32_t flags);
/**
+ * Free a contiguous block of shared memory
+ *
+ * Frees a previously reserved block of shared memory.
+ * @note Freeing memory that is in use will result in UNDEFINED behaviour.
+ *
+ * @param[in] shm Block handle
+ *
+ * @retval 0 for success
+ * @retval 1 on failure
+ */
+int odp_shm_free(odp_shm_t shm);
+
+/**
* Lookup for a block of shared memory
*
* @param name Name of the block
diff --git a/platform/linux-generic/odp_shared_memory.c
b/platform/linux-generic/odp_shared_memory.c
index c770a80..4e0f05e 100644
--- a/platform/linux-generic/odp_shared_memory.c
+++ b/platform/linux-generic/odp_shared_memory.c
@@ -10,6 +10,7 @@
#include <odp_align.h>
#include <odp_system_info.h>
#include <odp_debug.h>
+#include <odp_debug_internal.h>
#include <unistd.h>
#include <sys/mman.h>
@@ -219,6 +220,11 @@ odp_shm_t odp_shm_reserve(const char *name, uint64_t size,
uint64_t align,
return block->hdl;
}
+int odp_shm_free(odp_shm_t shm ODP_UNUSED)
+{
+ ODP_UNIMPLEMENTED();
+ return 0;
+}
odp_shm_t odp_shm_lookup(const char *name)
{
_______________________________________________
lng-odp mailing list
lng-odp@lists.linaro.org
http://lists.linaro.org/mailman/listinfo/lng-odp