setattr_copy_mgtime(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– NAME πŸ’–

setattr_copy_mgtime β€” update timestamps for mgtime inodes ✨

okay so first things first: this page is from the Kernel API Manual, and it’s here to explain a tiny-but-serious timestamp update helper. iykyk πŸ’…

✨ SYNOPSIS ✨

void setattr_copy_mgtime (struct inode *inode , const struct iattr *attr
       );

πŸŽ€ ARGUMENTS πŸŽ€

  • inode β€” inode timestamps to be updated. main character inode, got it? 🫢
  • attr β€” attrs for the update. it’s carrying the update deets.

πŸ¦‹ DESCRIPTION πŸ¦‹

With multigrain timestamps, this function takes more care to prevent races when updating the ctime. Always update the ctime to the very latest using the standard mechanism, and use that to populate the atime and mtime appropriately (unless those are being set to specific values). no cap, that last parenthetical is important β€” don’t let the specific-value case sneak past you 😭

🌈 SEE ALSO 🌈

xoxo bestie πŸ’– β€” source/version: ./fs; date: October 2026; title: setattr_copy_mgtime(9). that’s the footer vibe, periodt 🫢

πŸ“¦ where this page comes from