Kernel: add basic fcntl() with couple of commands and no validation

This commit is contained in:
Bananymous
2023-09-04 12:57:09 +03:00
parent a711462ef4
commit 6f002c926a
7 changed files with 50 additions and 0 deletions

View File

@@ -28,6 +28,8 @@ namespace Kernel
BAN::ErrorOr<int> dup(int);
BAN::ErrorOr<int> dup2(int, int);
BAN::ErrorOr<int> fcntl(int fd, int cmd, int extra);
BAN::ErrorOr<void> seek(int fd, off_t offset, int whence);
BAN::ErrorOr<off_t> tell(int) const;

View File

@@ -99,6 +99,8 @@ namespace Kernel
BAN::ErrorOr<long> sys_dup(int fildes);
BAN::ErrorOr<long> sys_dup2(int fildes, int fildes2);
BAN::ErrorOr<long> sys_fcntl(int fildes, int cmd, int extra);
BAN::ErrorOr<long> sys_seek(int fd, off_t offset, int whence);
BAN::ErrorOr<long> sys_tell(int fd);