20 bool old_value =
true;
23 __asm__
volatile (
"xchg (,%1,), %0":
"=a"(old_value):
"b"(mutex),
"a"(old_value));
24 }
while (old_value && wait);
bool mutex_get(mutex_t *mutex, bool wait)
Получить мьютекс
void mutex_release(mutex_t *mutex)
Получить ближайщий свободный блок