nilfs_ioctl_get_sustat(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… nilfs_ioctl_get_sustat(9) β€” get segment usage statistics ✨

okay so bestie, welcome to the Kernel API Manual for nilfs_ioctl_get_sustat(9) β€” yes that's the whole name, it's giving "my parents gave me a long name and I'm owning it" πŸŽ€


🌸 NAME 🌸

nilfs_ioctl_get_sustat β€” get segment usage statistics πŸ’–

It literally does what it says on the tin, no cap.


✨ SYNOPSIS ✨

int nilfs_ioctl_get_sustat (struct inode *inode , struct file *filp ,
       unsigned int cmd , void __user *argp );

four arguments, one int back, that's the whole vibe πŸ¦‹


🫢 ARGUMENTS 🫢

  • inode β€” the inode object, bestie. the main character of the file world πŸ‘‘
  • filp β€” the file object. it's giving "we're doing this on an open file" 🌈
  • cmd β€” the ioctl's request code. the lil "which thing are we doing" tag πŸŽ€
  • argp β€” a pointer to the argument from userspace. this is where the answers go, iykyk πŸ’«

πŸ’œ DESCRIPTION πŸ’œ

so, nilfs_ioctl_get_sustat returns segment usage statistics. periodt. πŸ“Š

the NILFS_IOCTL_GET_SUSTAT ioctl is what's used in lssu, in the nilfs_resize utilities, and by the nilfs_cleanerd daemon β€” like, those are its people, its little crew 🫢

the requested segment usage information gets copied to the userspace memory pointed to by argp. that's it, that's the whole job. slay. ✨


πŸ’€ RETURN πŸ’€

0 on success πŸŽ‰ or one of the following negative error codes on failure (ngl the failures are the relatable part):

  • -EFAULT β€” failure during getting segment usage statistics 😭
  • -EIO β€” I/O error πŸŒ€
  • -ENOMEM β€” insufficient memory available πŸ’€

πŸ¦‹ SEE ALSO πŸ¦‹

okay so this is the friend group, and honestly? it's a big one. go say hi:


and that's the whole page, bestie!! πŸ’… this lil manual page lives in ./fs/nilfs2 and it's dated October 2026 β€” go forth and read your segment usage statistics, i'm obsessed for you πŸ’–πŸŽ€βœ¨

πŸ“¦ where this page comes from