From 3bf07641ee5ba1c6ec56b81a7f34abe1267d3ac1 Mon Sep 17 00:00:00 2001 From: dzwdz Date: Wed, 4 May 2022 13:49:38 +0200 Subject: kernel: refcount vfs_backend what a mess --- src/kernel/vfs/request.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src/kernel/vfs/request.h') diff --git a/src/kernel/vfs/request.h b/src/kernel/vfs/request.h index 657ae85..69dad07 100644 --- a/src/kernel/vfs/request.h +++ b/src/kernel/vfs/request.h @@ -11,6 +11,14 @@ enum vfs_backend_type { // describes something which can act as an access function struct vfs_backend { + size_t refcount; + /* references: + * struct vfs_mount + * struct vfs_request + * struct process + * struct handle + */ + enum vfs_backend_type type; size_t potential_handlers; // 0 - orphaned @@ -52,3 +60,5 @@ int vfs_backend_accept(struct vfs_backend *); int vfs_request_finish(struct vfs_request *, int ret); void vfs_request_cancel(struct vfs_request *, int ret); + +void vfs_backend_refdown(struct vfs_backend *); -- cgit v1.2.3