diff options
author | dzwdz | 2024-07-11 21:43:50 +0200 |
---|---|---|
committer | dzwdz | 2024-07-11 21:43:50 +0200 |
commit | ed8ff1ff9c4c0f847ffc2ab4624bd999539a0890 (patch) | |
tree | 7dd5ad530f65fb09f6f0ce6c4d94efa2fc2d05d7 /src/kernel/vfs/request.h | |
parent | 8138ba97608ff0cd4e443994390f277eca3d7b28 (diff) |
kernel: start cleaning up VfsRequest
* I'm being more strict about the linked list state to hopefully ensure
I'm not leaking any references.
* vfsreq_create was renamed to vfsreq_dispatchcopy as that name feels more
clear. It copies its argument, and dispatches it.
* Requests for user backends are now handled more like requests for kernel
backends - there's an accept() function that accepts a request.
Diffstat (limited to 'src/kernel/vfs/request.h')
-rw-r--r-- | src/kernel/vfs/request.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/kernel/vfs/request.h b/src/kernel/vfs/request.h index 2bd8c61..0b93491 100644 --- a/src/kernel/vfs/request.h +++ b/src/kernel/vfs/request.h @@ -3,7 +3,6 @@ #include <stdbool.h> #include <stddef.h> -/* describes something which can act as an access function */ struct VfsBackend { /* amount of using references * VfsMount @@ -14,6 +13,7 @@ struct VfsBackend { /* amount of providing references * Proc * 0 - orphaned, will never increase */ + // TODO move this into .user size_t provhcnt; VfsReq *queue; @@ -64,7 +64,7 @@ struct VfsReq { }; /** Assigns the vfs_request to the caller, and dispatches the call */ -void vfsreq_create(VfsReq); +void vfsreq_dispatchcopy(VfsReq); void vfsreq_finish(VfsReq*, char __user *stored, long ret, int flags, Proc *handler); static inline void vfsreq_finish_short(VfsReq *req, long ret) { @@ -72,7 +72,7 @@ static inline void vfsreq_finish_short(VfsReq *req, long ret) { } /** Try to accept an enqueued request */ -void vfs_backend_tryaccept(VfsBackend *); +void vfsback_useraccept(VfsReq *); /** Decrements the "user" reference count. */ void vfsback_userdown(VfsBackend *); |