fh_want_write(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… fh_want_write(9)

ok so this is a page from the Kernel API Manual bestie, and it's literally about fh_want_write β€” the little function that asks "hey, can I write to this export or not?" πŸŽ€


✨ NAME ✨

fh_want_write β€” Get write access to an export 🌸


πŸ¦‹ SYNOPSIS πŸ¦‹

int fh_want_write (struct svc_fh *fhp );

πŸŽ€ ARGUMENTS πŸŽ€

  • fhp β€” File handle of file to be written. that's the one, the file handle, the whole point 🫢

πŸ’– DESCRIPTION πŸ’–

ok so listen πŸ‘‘ β€” the caller must invoke fh_drop_write when its write operation is complete. like, that's not a suggestion, that's the rule, no cap πŸ’…

It returns 0 if the file handle's export can be written to. slay, go off ✨

Otherwise? the export is not prepared for updates, and the returned negative errno value reflects the reason for the failure. so if you get a negative number back, that's your explanation right there, iykyk πŸ”₯

real talk bestie: the fh_drop_write follow-up is mandatory, not optional. don't leave it hanging 😭

🌈 SEE ALSO 🌈


and that's the whole page, bestie, you ate that πŸ“ πŸ’œ

mwah πŸ’‹ β€” brought to you by ./fs/nfsd, dated October 2026 ✨

πŸ“¦ where this page comes from