ext4_get_group_desc(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ ext4_get_group_desc(9) ✨

okay so bestie, welcome to the Kernel API Manual πŸ’– this one's a kernel-API page, section 9, and it's all about grabbing a group descriptor off the disk. it's giving "short but mighty" and honestly? iconic.


πŸŽ€ NAME πŸŽ€

ext4_get_group_desc β€” load group descriptor from disk

like literally, that's the whole job. load. group descriptor. from. disk. periodt. πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

struct ext4_group_desc * ext4_get_group_desc (struct super_block *sb ,
ext4_group_t block_group , struct buffer_head **bh );

not me dropping the full signature so you can copy it exactly 🫢 β€” it returns a struct ext4_group_desc *, and it takes three things. let's get into them πŸ‘‡


🌸 ARGUMENTS 🌸

  • sb β€” the super block πŸ’« yeah, that one. your super block.
  • block_group β€” the given block group. that's the group you're asking about, no cap.
  • bh β€” pointer to the buffer head to store the block group descriptor πŸ‘‘ so it's a pointer-to-a-pointer situation, and that's where the descriptor's buffer head ends up living.
ngl, bh is the sneaky one β€” it's a struct buffer_head **, so you're handing over the address of your pointer. do not hand it a plain pointer, bestie, i'm begging 😭

🌈 SEE ALSO 🌈

this is the friend group of related functions, and they all ate fr fr πŸ”₯

Kernel file ./fs/ext4/balloc.c β€” that's the home base for this one, go say hi πŸ’œ


and that's the whole page!! short, sweet, and extremely useful πŸ’– iykyk.

so yeah β€” this whole thing lives under ./fs/ext4, and it's dated October 2026, version vibe and all, with ext4_get_group_desc(9) stamped right on the footer like a lil signature πŸŽ€ mwah, go read a group descriptor, main character πŸ§šβ€β™€οΈβœ¨

πŸ“¦ where this page comes from