aboutsummaryrefslogtreecommitdiff
path: root/sys/include
diff options
context:
space:
mode:
authorIan Moffett <ian@osmora.org>2024-09-09 14:12:10 -0400
committerIan Moffett <ian@osmora.org>2024-09-09 14:13:01 -0400
commitcaad8d9443d1e751ba743de660cc1d592faae5d9 (patch)
treee2084ebd446dc1a03539a94b088755421d789554 /sys/include
parent3b86fcc44502c3c25a837885d358aa9200c122e1 (diff)
kernel: vfs: Refactor fd related code
Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'sys/include')
-rw-r--r--sys/include/sys/filedesc.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/include/sys/filedesc.h b/sys/include/sys/filedesc.h
index dbac349..f5f24db 100644
--- a/sys/include/sys/filedesc.h
+++ b/sys/include/sys/filedesc.h
@@ -43,4 +43,11 @@ struct filedesc {
struct spinlock lock;
};
+int fd_close(unsigned int fd);
+int fd_read(unsigned int fd, void *buf, size_t count);
+
+int fd_alloc(struct filedesc **fd_out);
+int fd_open(const char *pathname, int flags);
+struct filedesc *fd_get(unsigned int fdno);
+
#endif /* !_SYS_FILEDESC_H_ */