nilfs_sufile_set_suinfo(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– nilfs_sufile_set_suinfo(9) πŸ’–

ok so this is a page from the Kernel API Manual β€” yes bestie, we're in kernel land today, put your hair up, we're going in 🧚✨


✨ NAME ✨

nilfs_sufile_set_suinfo β€” sets segment usage info πŸŽ€

like, it literally updates the segment usage info. that's the whole vibe. no cap.


🌸 SYNOPSIS 🌸

ssize_t nilfs_sufile_set_suinfo (struct inode *sufile , void *buf ,
       unsigned int supsz , size_t nsup );

πŸ¦‹ ARGUMENTS πŸ¦‹

  • sufile β€” the inode of the segment usage file πŸ’… that's your main character right there.
  • buf β€” an array of suinfo_update πŸ‘‘ yes, an array, plural energy.
  • supsz β€” the byte size of a suinfo_update πŸ“ (one of them, not the whole pile)
  • nsup β€” the size of the suinfo_update array 🌈 i.e. how many of them you're handing over.

πŸ’œ DESCRIPTION πŸ’œ

okay so picture this: you hand it an array of nilfs_suinfo_update structs, and it updates the segment usage accordingly. that's it. that's the function. ate and left no crumbs πŸ”₯

but here's the important part, bestie β€” only the fields indicated by the sup_flags get updated. the way that it's selective?? iconic. it will not touch what you didn't ask it to touch πŸ™ˆ


⭐ RETURN ⭐

0 on success πŸŽ‰ or one of these negative error codes when it's not giving:

  • -EINVAL β€” invalid values in the input πŸ’€ specifically the segment number, flags or nblocks. check your inputs before you come at it like that.
  • -EIO β€” I/O error 😭 and yes, that includes metadata corruption, so like… be aware.
  • -ENOMEM β€” not enough memory available 🫢 the classic. insufficient memory, insufficient vibes.

πŸ“ SEE ALSO πŸ“

like, the whole sufile friend group 🫢 go read all of them, iykyk πŸ’…


and that's the page!! mwah πŸ’‹ sourced straight from ./fs/nilfs2, dated October 2026 β€” so like, freshly stamped, go forth and set that suinfo bestie πŸŒŸπŸ¦‹πŸ’–

πŸ“¦ where this page comes from