From 17a762fd36d5a226780930862486e8a7a35485ab Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Sun, 19 Jan 2020 08:57:27 +1100 Subject: [PATCH] AP_Notify: make all semaphores recursive the cost is very similar and this prevents an easy coding error which can occur on less used code paths --- libraries/AP_Notify/NeoPixel.h | 2 +- libraries/AP_Notify/OreoLED_I2C.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/libraries/AP_Notify/NeoPixel.h b/libraries/AP_Notify/NeoPixel.h index d5335ba7e3..88bbad43e1 100644 --- a/libraries/AP_Notify/NeoPixel.h +++ b/libraries/AP_Notify/NeoPixel.h @@ -43,5 +43,5 @@ private: // periodic callback void timer(); - HAL_Semaphore_Recursive _sem; + HAL_Semaphore _sem; }; diff --git a/libraries/AP_Notify/OreoLED_I2C.h b/libraries/AP_Notify/OreoLED_I2C.h index 7a5ce60000..76ed1a114d 100644 --- a/libraries/AP_Notify/OreoLED_I2C.h +++ b/libraries/AP_Notify/OreoLED_I2C.h @@ -179,7 +179,7 @@ private: // private members uint8_t _bus; - HAL_Semaphore_Recursive _sem; + HAL_Semaphore _sem; AP_HAL::OwnPtr _dev; bool _send_required; // true when we need to send an update to at least one led oreo_state _state_desired[OREOLED_NUM_LEDS]; // desired state