diff options
author | dzwdz | 2022-05-05 22:47:12 +0200 |
---|---|---|
committer | dzwdz | 2022-05-05 22:47:12 +0200 |
commit | a40063321e8fbf4d82f46471221062bfa393604a (patch) | |
tree | df4bb43830c0f94f90738d841b5caeb72922cda6 /src/kernel/vfs/request.h | |
parent | 9900cc737988f25db30b5876f066a78e73389205 (diff) |
kernel: each driver registers its own mounts
Diffstat (limited to 'src/kernel/vfs/request.h')
-rw-r--r-- | src/kernel/vfs/request.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/kernel/vfs/request.h b/src/kernel/vfs/request.h index 9dc6088..e034bc6 100644 --- a/src/kernel/vfs/request.h +++ b/src/kernel/vfs/request.h @@ -14,6 +14,7 @@ struct vfs_backend { * struct process * struct handle */ + bool heap; size_t potential_handlers; // 0 - orphaned struct vfs_request *queue; @@ -64,3 +65,11 @@ void vfs_backend_tryaccept(struct vfs_backend *); void vfs_backend_user_accept(struct vfs_request *req); void vfs_backend_refdown(struct vfs_backend *); + + +#define BACKEND_KERN(ready, accept) ((struct vfs_backend){\ + .is_user = false, \ + .heap = false, \ + .potential_handlers = 1, \ + .refcount = 1, \ + .kern = {ready, accept}}) |