gfs2_drop_inode(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… gfs2_drop_inode β€” the Kernel API Manual page, but make it make sense

okay so bestie, gather round, because today we're reading gfs2_drop_inode(9) from the Kernel API Manual and honestly? it's giving "tiny function, huge lore" πŸ’–


✨ NAME ✨

gfs2_drop_inode β€” drop an inode (and like, test for remote unlink while you're at it) 🫢


🌸 SYNOPSIS 🌸

int gfs2_drop_inode (struct inode *inode );

that's it. that's the whole signature. one (1) argument. we love a low-maintenance icon πŸ‘‘


πŸŽ€ ARGUMENTS πŸŽ€

  • inode β€” the inode we're dropping. that's the one. the whole vibe. the inode to drop πŸ’…

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so picture this: we've received a callback on an iopen lock. why? because a remote node tried to deallocate the inode and failed β€” and the reason it failed is that this node (us, hi, we're the problem) still had the inode open. awkward 😭

so here's what we do: we mark the link count zero. why are we so confident? because we know it must have reached zero if the GLF_DEMOTE flag is set on the iopen glock. like, the math is mathing ✨

and here's the fear: if we didn't do a disk read since the remote node removed the final link, then we might otherwise miss this event entirely. πŸ™ˆ so this check exists to make sure this node will deallocate the inode's blocks β€” or, alternatively, pass the baton on to another node for later deallocation. teamwork, bestie 🀝


πŸ’€ SEE ALSO πŸ’€

kernel file ./fs/gfs2/super.c β€” and friends!! go read the whole friend group:


🌈 the sign-off 🌈

this lil masterpiece lives in ./fs/gfs2, it's dated October 2026, and it's the Kernel API Manual β€” so, respectfully, cite it right. 🧚 slay, stay glocked, and don't forget to drop your inodes responsibly πŸ’œ

πŸ“¦ where this page comes from