From 681b37266861b2f3d35e50d43b146691cdfe7281 Mon Sep 17 00:00:00 2001 From: Andste82 Date: Fri, 30 Aug 2024 11:28:16 +0200 Subject: [PATCH] fix(spinlock): comparison of integer expressions of different signedness --- components/esp_hw_support/include/spinlock.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/esp_hw_support/include/spinlock.h b/components/esp_hw_support/include/spinlock.h index e16e83829c..66f825efce 100644 --- a/components/esp_hw_support/include/spinlock.h +++ b/components/esp_hw_support/include/spinlock.h @@ -134,7 +134,7 @@ static inline bool __attribute__((always_inline)) spinlock_acquire(spinlock_t *l break; } // Keep looping if we are waiting forever, or check if we have timed out - } while ((timeout == SPINLOCK_WAIT_FOREVER) || (esp_cpu_get_cycle_count() - start_count) <= timeout); + } while ((timeout == SPINLOCK_WAIT_FOREVER) || (esp_cpu_get_cycle_count() - start_count) <= (esp_cpu_cycle_count_t)timeout); exit: if (lock_set) {