read_bbt(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… read_bbt β€” yes bestie, it's a whole kernel function

So this is a page from the Kernel API Manual, and the function we're simping over today is read_bbt. Strap in, it's giving "low-level NAND vibes" and honestly? We're obsessed. 🌸


✨ NAME ✨

read_bbt β€” [GENERIC] read the bad block table, starting from a page. That's it, that's the whole gig. πŸ’–


πŸŽ€ SYNOPSIS πŸŽ€

int read_bbt (struct nand_chip *this , uint8_t *buf , int page , int num
, struct nand_bbt_descr *td , int offs );

Like, look at that signature. Six whole arguments. Main character energy fr fr. ✨


πŸ¦‹ ARGUMENTS πŸ¦‹

  • this β€” the NAND chip object. Yeah, it's literally called this. Iconic naming choice, no notes. πŸ‘‘
  • buf β€” a temporary buffer. It's just passing through, doing its little job. 🫢
  • page β€” the starting page. Where the reading begins, bestie. πŸ“–
  • num β€” how many bbt descriptors to read. Count carefully, ngl. πŸ”’
  • td β€” the bbt describtion table. (Yes we're spelling it like that, it's canon.) πŸŽ€
  • offs β€” block number offset in the table. Offset queen. πŸ’…

πŸ’œ DESCRIPTION πŸ’œ

Read the bad block table starting from page. 🌈

That's genuinely the whole description. Short king of a description. It ate and left no crumbs, but also left no extra details, so don't go looking for lore that isn't there. 😭

Lowkey important: this reads the bad block table starting from page β€” that's the starting point, not some random spot. No cap. πŸ”₯

🌟 SEE ALSO 🌟

Everything here lives in the kernel file ./drivers/mtd/nand/raw/nand_bbt.c β€” and the friend group is huge. Miss nothing: πŸ’€

Twenty-two entries. Twenty-two!! The way this function has more connections than a group chat on a Friday night. 🧚


Byeee bestie β€” this one's filed under ./drivers/mtd/nand/raw, dated October 2026, page read_bbt(9). Go read a bad block table for me, mwah πŸ’‹

πŸ“¦ where this page comes from