diff options
Diffstat (limited to 'sys/include')
-rw-r--r-- | sys/include/sys/vnode.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/include/sys/vnode.h b/sys/include/sys/vnode.h index 545fa2f..3f3b011 100644 --- a/sys/include/sys/vnode.h +++ b/sys/include/sys/vnode.h @@ -31,6 +31,7 @@ #define _SYS_VNODE_H_ #include <sys/types.h> +#include <sys/atomic.h> #include <sys/sio.h> #if defined(_KERNEL) @@ -42,8 +43,11 @@ struct vnode { int flags; void *data; const struct vops *vops; + uint32_t refcount; }; +#define vfs_vref(VP) (atomic_inc_int(&(VP)->refcount)) + /* Vnode type flags */ #define VNON 0x00 /* Uninitialized */ #define VREG 0x01 /* Regular file */ |