d37fa7e244
esp_cpu_compare_and_set() abstracts the atomic compare-and-set instruction by hiding the details of whether the target variable is in internal or external RAM. This commit updates "spinlocks.h" as follows: - esp_cpu_compare_and_set() is now called instead of "compare_set.h" - Refactored spinlock logic to be more optimized and have more stringent sanity checks