reorder includes

This commit is contained in:
Matheus
2023-05-29 10:49:09 -03:00
parent 74924c4d11
commit acf4a9819f
2 changed files with 6 additions and 4 deletions
+1
View File
@@ -3,6 +3,7 @@
#include <kernel/vfs.h> #include <kernel/vfs.h>
#include <mutex.h> #include <mutex.h>
#include <kernel/scheduler.h>
typedef struct file_t { typedef struct file_t {
vnode_t *vnode; vnode_t *vnode;
+5 -4
View File
@@ -3,16 +3,15 @@
#include <stdbool.h> #include <stdbool.h>
#include <spinlock.h> #include <spinlock.h>
#include <kernel/scheduler.h>
#define SEM_TAIL 0 #define SEM_TAIL 0
#define SEM_HEAD 1 #define SEM_HEAD 1
typedef struct { typedef struct semaphore_t{
int i; int i;
spinlock_t lock; spinlock_t lock;
thread_t *tail; struct thread_t *tail;
thread_t *head; struct thread_t *head;
} semaphore_t; } semaphore_t;
#define SEMAPHORE_INIT(x, v) { \ #define SEMAPHORE_INIT(x, v) { \
@@ -26,4 +25,6 @@ int semaphore_wait(semaphore_t *sem, bool interruptible);
void semaphore_signal(semaphore_t *sem); void semaphore_signal(semaphore_t *sem);
bool semaphore_test(semaphore_t *sem); bool semaphore_test(semaphore_t *sem);
#include <kernel/scheduler.h>
#endif #endif