From 592328bc3f7afbec3284338c541627220e78422d Mon Sep 17 00:00:00 2001 From: Jacob Hageman Date: Wed, 25 Mar 2020 11:16:52 -0400 Subject: [PATCH] Fix #18, Depreacate OS_ShMem* --- src/os/inc/osapi-os-core.h | 15 +++++++++------ .../ut-stubs/src/osapi-base-impl-stubs.c | 2 ++ 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/src/os/inc/osapi-os-core.h b/src/os/inc/osapi-os-core.h index d6d89d4b0..36e3f34d0 100644 --- a/src/os/inc/osapi-os-core.h +++ b/src/os/inc/osapi-os-core.h @@ -1294,6 +1294,7 @@ int32 OS_IntGetMask (uint32 *mask); int32 OS_IntAck (int32 InterruptNumber); /**@}*/ +#ifndef OSAL_OMIT_DEPRECATED /** * @defgroup OSAPIShMem OSAL Shared memory APIs * @deprecated Not in current implementations @@ -1302,42 +1303,44 @@ int32 OS_IntAck (int32 InterruptNumber); */ /*-------------------------------------------------------------------------------------*/ -/** @brief placeholder; not currently implemented +/** @brief DEPRECATED - platform dependent, never implemented in framework OSALs * @deprecated Never implemented */ int32 OS_ShMemInit (void); /*-------------------------------------------------------------------------------------*/ -/** @brief placeholder; not currently implemented +/** @brief DEPRECATED - platform dependent, never implemented in framework OSALs * @deprecated Never implemented */ int32 OS_ShMemCreate (uint32 *Id, uint32 NBytes, const char* SegName); /*-------------------------------------------------------------------------------------*/ -/** @brief placeholder; not currently implemented +/** @brief DEPRECATED - platform dependent, never implemented in framework OSALs * @deprecated Never implemented */ int32 OS_ShMemSemTake (uint32 Id); /*-------------------------------------------------------------------------------------*/ -/** @brief placeholder; not currently implemented +/** @brief DEPRECATED - platform dependent, never implemented in framework OSALs * @deprecated Never implemented */ int32 OS_ShMemSemGive (uint32 Id); /*-------------------------------------------------------------------------------------*/ -/** @brief placeholder; not currently implemented +/** @brief DEPRECATED - platform dependent, never implemented in framework OSALs * @deprecated Never implemented */ int32 OS_ShMemAttach (cpuaddr * Address, uint32 Id); /*-------------------------------------------------------------------------------------*/ -/** @brief placeholder; not currently implemented +/** @brief DEPRECATED - platform dependent, never implemented in framework OSALs * @deprecated Never implemented */ int32 OS_ShMemGetIdByName (uint32 *ShMemId, const char *SegName ); /**@}*/ +#endif /* OSAL_OMIT_DEPRECATED */ + /** @defgroup OSAPIHeap OSAL Heap APIs * @{ */ diff --git a/src/unit-test-coverage/ut-stubs/src/osapi-base-impl-stubs.c b/src/unit-test-coverage/ut-stubs/src/osapi-base-impl-stubs.c index cb660a5a0..504ae52e6 100644 --- a/src/unit-test-coverage/ut-stubs/src/osapi-base-impl-stubs.c +++ b/src/unit-test-coverage/ut-stubs/src/osapi-base-impl-stubs.c @@ -123,6 +123,7 @@ void OS_ConsoleOutput_Impl(uint32 local_id) UT_DEFAULT_IMPL(OS_ConsoleOutput_Impl); } +#ifndef OSAL_OMIT_DEPRECATED /* ** Shared memory API */ @@ -132,6 +133,7 @@ UT_DEFAULT_STUB(OS_ShMemSemTake_Impl,(uint32 Id)) UT_DEFAULT_STUB(OS_ShMemSemGive_Impl,(uint32 Id)) UT_DEFAULT_STUB(OS_ShMemAttach_Impl,(uint32 * Address, uint32 Id)) UT_DEFAULT_STUB(OS_ShMemGetIdByName_Impl,(uint32 *ShMemId, const char *SegName )) +#endif /* OSAL_OMIT_DEPRECATED */ /*