Luna/kernel/include/thread
apio da2ede3450 Kernel, libc, userspace: Implement file descriptors
Kernel: Implement a descriptor struct which stores the opened node and read offset, and give each task 8 of those.
Implement three syscalls: sys_read, sys_open and sys_close (sys_write still writes to the console instead of using a fd, for now)
Implement three new errors: ENOENT, EBADF and EMFILE.

libc: Implement the new errors, and the new syscalls in syscall().
Also fix _RETURN_WITH_ERRNO() to set errno correctly, which was making strerror() return null, thus crashing perror().

userspace: make init demonstrate the new file API.
2022-10-10 20:21:39 +02:00
..
PIT.h Reorganize structure 2022-09-21 17:56:53 +02:00
Scheduler.h Kernel, libc: Add support for providing a status code to exit() 2022-10-08 17:56:40 +02:00
Spinlock.h Add spinlocks 2022-09-18 20:15:19 +02:00
Task.h Kernel, libc, userspace: Implement file descriptors 2022-10-10 20:21:39 +02:00