VFS_ROOT(9)
π VFS_ROOT π β like, the kernel dev's manual, section 9, bestie π
okay so this is VFS_ROOT from the Kernel Developer's Manual (that's section 9, for the uninitiated β iykyk). it's a lil function that hands you the root vnode of a file system. that's it. that's the whole vibe. β¨
πΈ NAME πΈ
VFS_ROOT β return the root vnode of a file system π¦
β¨ SYNOPSIS β¨
#include <sys/param.h>
#include <sys/mount.h>
#include <sys/vnode.h>
int
VFS_ROOT(struct mount *mp, int flags, struct vnode **vpp);
like, literally just include those three headers first or nothing works, bestie π
π DESCRIPTION π
Return a locked vnode for the root directory of the file system. that's the whole job. it shows up, it locks the root dir, it hands it to you. main character energy fr fr π
its arguments are, and listen because these matter:
mpβ the file system. the whole thing. the entire vibe. ποΈflagsβ the lock type. could beLK_EXCLUSIVEorLK_SHARED. but heads up bestie: the file system is free to ignore theflagsargument and instead acquire an exclusive lock. so don't be out here assuming you got what you asked for, okay? π«vppβ return parameter for the root vnode. this is where the root vnode goes when the function is done being iconic. π«
π¦ SEE ALSO π¦
go read those too, no cap, they're the whole friend group π
π AUTHORS π
This manual page was written by Doug Rabson. king behavior honestly π
and that's the page!! Debian, dated May 23, 2009 β yeah she's a lil vintage but she still eats πβ¨ππ¦πΈπ π«Ά
π¦ where this page comes from
- debian bookworm: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- debian trixie: freebsd-manpages 12.2-2 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu jammy: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu noble: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu questing: freebsd-manpages 12.2-2
- ubuntu resolute: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu stonking: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- Copyright (c) 1996 Doug Rabson
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms