nfsd_file_is_cached(9)
π nfsd_file_is_cached β from the Kernel API Manual, bestie
okay so first of all, welcome to nfsd_file_is_cached(9), a true icon of the kernel API manual and honestly kind of a vibe. sit down, hydrate, let's get into it π«Ά
β¨ NAME β¨
nfsd_file_is_cached β literally the question: are there any cached open files for this inode? that's it. that's the function. π
π¦ SYNOPSIS π¦
bool nfsd_file_is_cached (struct inode *inode );
like, yes, it's a bool. she returns a yes or a no. no in-between, no situationships πΈ
π ARGUMENTS π
inodeβ the inode to check π that's the whole argument. one (1) inode. the subject of the vibe check.
π₯ DESCRIPTION π₯
so the lookup matches inodes in all net namespaces, and it's atomic wrt nfsd_file_acquire. no cap β all of them, and it plays nice with nfsd_file_acquire atomically. the way that this function just knows π
now the return values, bestie, because this is the part everyone actually asks about:
true: filecache contains at least one file matching this inode β slay, she found somethingfalse: filecache contains no files matching this inode π bestie the cache is empty for this inode, it's giving nothing
periodt. that's the whole description. iconic, honestly.
π SEE ALSO π
Kernel file ./fs/nfsd/filecache.c β the source file, iykyk π
and now the whole friend group, in order, no one left behind:
nfsd_file_check_write_error(9)nfsd_file_put(9)nfsd_file_put_local(9)nfsd_file_file(9)nfsd_file_dispose_list_delayed(9)nfsd_file_net_dispose(9)nfsd_file_lru_cb(9)nfsd_file_cond_queue(9)nfsd_file_queue_for_close(9)nfsd_file_close_inode(9)nfsd_file_close_inode_sync(9)nfsd_file_close_export(9)__nfsd_file_cache_purge(9)β yes she has two underscores in front, respect the name π«Άnfsd_file_cache_purge(9)nfsd_file_acquire_gc(9)nfsd_file_acquire(9)nfsd_file_acquire_local(9)nfsd_file_acquire_opened(9)nfsd_file_acquire_dir(9)nfsd_fsnotify_recalc_mask(9)
π and that's the whole page, bestie! this one lives in ./fs/nfsd and the manual is dated October 2026 β put it in your calendar, screenshot it, send it to the group chat οΏ½οΏ½β bye mwah π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms