From 6b441b134e91ed41113d1996827900d032f8ec5c Mon Sep 17 00:00:00 2001 From: Oskar Weigl Date: Tue, 23 Oct 2018 23:29:43 -0700 Subject: [PATCH] bake patch: fix return type of osSemaphoreWait --- ...1-fix-return-type-of-osSemaphoreWait.patch | 46 ------------------- .../FreeRTOS/Source/CMSIS_RTOS/cmsis_os.c | 4 +- .../FreeRTOS/Source/CMSIS_RTOS/cmsis_os.h | 4 +- 3 files changed, 4 insertions(+), 50 deletions(-) delete mode 100644 Firmware/Board/v3/0001-fix-return-type-of-osSemaphoreWait.patch diff --git a/Firmware/Board/v3/0001-fix-return-type-of-osSemaphoreWait.patch b/Firmware/Board/v3/0001-fix-return-type-of-osSemaphoreWait.patch deleted file mode 100644 index 53760fa1..00000000 --- a/Firmware/Board/v3/0001-fix-return-type-of-osSemaphoreWait.patch +++ /dev/null @@ -1,46 +0,0 @@ -From 49353ccb7023c02c2bc6e3b6f14fac02a13fe599 Mon Sep 17 00:00:00 2001 -From: Samuel Sadok -Date: Mon, 26 Feb 2018 14:55:17 -0800 -Subject: [PATCH] fix return type of osSemaphoreWait - ---- - .../Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.c | 6 +++--- - .../Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.h | 6 +++--- - 2 files changed, 6 insertions(+), 6 deletions(-) - -diff --git a/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.c b/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.c -index d0e0fd7..e764cbc 100644 ---- a/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.c -+++ b/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.c -@@ -816,10 +816,10 @@ osSemaphoreId osSemaphoreCreate (const osSemaphoreDef_t *semaphore_def, int32_t - * @brief Wait until a Semaphore token becomes available - * @param semaphore_id semaphore object referenced with \ref osSemaphore. - * @param millisec timeout value or 0 in case of no time-out. --* @retval number of available tokens, or -1 in case of incorrect parameters. -+* @retval status code that indicates the execution status of the function. - * @note MUST REMAIN UNCHANGED: \b osSemaphoreWait shall be consistent in every CMSIS-RTOS. - */ --int32_t osSemaphoreWait (osSemaphoreId semaphore_id, uint32_t millisec) -+osStatus osSemaphoreWait (osSemaphoreId semaphore_id, uint32_t millisec) - { - TickType_t ticks; - portBASE_TYPE taskWoken = pdFALSE; -diff --git a/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.h b/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.h -index 15e25b9..5223f8e 100644 ---- a/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.h -+++ b/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.h -@@ -719,9 +719,9 @@ osSemaphoreId osSemaphoreCreate (const osSemaphoreDef_t *semaphore_def, int32_t - /// Wait until a Semaphore token becomes available. - /// \param[in] semaphore_id semaphore object referenced with \ref osSemaphoreCreate. - /// \param[in] millisec timeout value or 0 in case of no time-out. --/// \return number of available tokens, or -1 in case of incorrect parameters. -+/// \return status code that indicates the execution status of the function. - /// \note MUST REMAIN UNCHANGED: \b osSemaphoreWait shall be consistent in every CMSIS-RTOS. --int32_t osSemaphoreWait (osSemaphoreId semaphore_id, uint32_t millisec); -+osStatus osSemaphoreWait (osSemaphoreId semaphore_id, uint32_t millisec); - - /// Release a Semaphore token. - /// \param[in] semaphore_id semaphore object referenced with \ref osSemaphoreCreate. --- -2.16.1 - diff --git a/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.c b/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.c index d0e0fd76..7828403b 100644 --- a/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.c +++ b/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.c @@ -816,10 +816,10 @@ osSemaphoreId osSemaphoreCreate (const osSemaphoreDef_t *semaphore_def, int32_t * @brief Wait until a Semaphore token becomes available * @param semaphore_id semaphore object referenced with \ref osSemaphore. * @param millisec timeout value or 0 in case of no time-out. -* @retval number of available tokens, or -1 in case of incorrect parameters. +* @retval status code that indicates the execution status of the function. * @note MUST REMAIN UNCHANGED: \b osSemaphoreWait shall be consistent in every CMSIS-RTOS. */ -int32_t osSemaphoreWait (osSemaphoreId semaphore_id, uint32_t millisec) +osStatus osSemaphoreWait (osSemaphoreId semaphore_id, uint32_t millisec) { TickType_t ticks; portBASE_TYPE taskWoken = pdFALSE; diff --git a/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.h b/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.h index 15e25b96..09cdf273 100644 --- a/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.h +++ b/Firmware/Board/v3/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.h @@ -719,9 +719,9 @@ osSemaphoreId osSemaphoreCreate (const osSemaphoreDef_t *semaphore_def, int32_t /// Wait until a Semaphore token becomes available. /// \param[in] semaphore_id semaphore object referenced with \ref osSemaphoreCreate. /// \param[in] millisec timeout value or 0 in case of no time-out. -/// \return number of available tokens, or -1 in case of incorrect parameters. +/// \return status code that indicates the execution status of the function. /// \note MUST REMAIN UNCHANGED: \b osSemaphoreWait shall be consistent in every CMSIS-RTOS. -int32_t osSemaphoreWait (osSemaphoreId semaphore_id, uint32_t millisec); +osStatus osSemaphoreWait (osSemaphoreId semaphore_id, uint32_t millisec); /// Release a Semaphore token. /// \param[in] semaphore_id semaphore object referenced with \ref osSemaphoreCreate.