Files
mop3/kernel/sync/spin_lock.h
kamkow1 e5ebd7f3ba
All checks were successful
Build ISO image / build-and-deploy (push) Successful in 2m21s
Build documentation / build-and-deploy (push) Successful in 54s
Use a big-lock for kernel sychronization instead of fine-grained locking
2026-04-27 18:06:02 +02:00

16 lines
297 B
C

#ifndef _KERNEL_SYNC_SPIN_LOCK_H
#define _KERNEL_SYNC_SPIN_LOCK_H
#include <libk/std.h>
#include <sys/spin_lock.h>
#define SPIN_LOCK_INIT ATOMIC_FLAG_INIT
typedef atomic_flag spin_lock_t;
void spin_lock(spin_lock_t* sl);
void spin_unlock(spin_lock_t* sl);
#endif // _KERNEL_SYNC_SPIN_LOCK_H