kernel: finish work of removing interruptible mutexes

This commit is contained in:
Matheus
2024-12-24 21:30:25 -03:00
parent 48643c4868
commit a6c169e5e6
42 changed files with 169 additions and 169 deletions
+1 -1
View File
@@ -30,7 +30,7 @@ int fd_setflags(int fd, int flags);
int fd_getflags(int fd, int *flags);
int fd_insert(file_t *file, int *fdp);
#define FILE_LOCK(x) MUTEX_ACQUIRE(&(x)->mutex, false)
#define FILE_LOCK(x) MUTEX_ACQUIRE(&(x)->mutex)
#define FILE_UNLOCK(x) MUTEX_RELEASE(&(x)->mutex)
#define FILE_READ 1
+1 -1
View File
@@ -86,7 +86,7 @@ typedef struct proc_t {
// the acquire of the pid table mutex is done here to prevent a nasty race condition where sched_inactiveproc could be called multiple times
// due to the pid table itself not holding any references to the process
#define PROC_RELEASE(v) {\
MUTEX_ACQUIRE(&proc_pid_table_mutex, false); \
MUTEX_ACQUIRE(&proc_pid_table_mutex); \
if (__atomic_sub_fetch(&(v)->refcount, 1, __ATOMIC_SEQ_CST) == 0) {\
proc_inactive(v); \
(v) = NULL; \