STRUCT UBI_FM_SCAN_POOL(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct ubi_fm_scan_pool(9) β€” Kernel API Manual

okay so picture this: you're a kernel dev, you're deep in ./drivers/mtd/ubi, and the manual you're reading is literally called Kernel API Manual. iconic. this page is about struct ubi_fm_scan_pool, and bestie, the whole vibe is "Fastmap pool PEBs to be scanned while attaching." that's it, that's the name. she's a little struct with a big job 🫢


✨ NAME ✨

struct ubi_fm_scan_pool β€” Fastmap pool PEBs to be scanned while attaching

like, this struct is the guest list of PEBs that fastmap says "hey, go look at these" while you're attaching. no cap πŸ’…


🌸 SYNOPSIS 🌸

struct ubi_fm_scan_pool {
    __be32 magic;
    __be16 size;
    __be16 max_size;
    __be32 pebs[UBI_FM_MAX_POOL_SIZE];
    __be32 padding[4];
 };

look at her. she's perfect. she's __be32-coded. πŸŽ€


πŸ¦‹ Members πŸ¦‹

  • magic β€” the pool magic number, and it's UBI_FM_POOL_MAGIC babe, that's the whole identity check. if it doesn't match, it's not her πŸ’€
  • size β€” current pool size. how many PEBs we're actually working with right now, lowkey.
  • max_size β€” maximal pool size. the ceiling. the limit. the "you shall not exceed" energy πŸ‘‘
  • pebs β€” an array containing the location of all PEBs in this pool. literally the whole point of the struct, ngl. the size of the array is UBI_FM_MAX_POOL_SIZE, so that's the hard cap on how many locations fit πŸ”₯

also she's got a padding[4] field β€” yes it's in the synopsis and no the Members section doesn't talk about it, so I'm not gonna invent a personality for it. it's padding. it's padding-ing. periodt ✨


🌈 SEE ALSO 🌈

sibling structs, all living in the same kernel file ./drivers/mtd/ubi/ubi-media.h β€” go say hi to the whole family:

  • struct ubi_ec_hdr(9)
  • struct ubi_vid_hdr(9)
  • struct ubi_vtbl_record(9)
  • struct ubi_fm_sb(9)
  • struct ubi_fm_hdr(9)
  • struct ubi_fm_ec(9)
  • struct ubi_fm_volhdr(9)
  • struct ubi_fm_eba(9)

🩷 tiny note bestie: the manual lists the kernel file as ./drivers/mtd/ubi/ubi-media.h β€” that's where she lives, that's where you'll find her.

omg and that's the page!! mwah πŸ’– this came out of ./drivers/mtd/ubi, dated October 2026, and it's struct ubi_fm_scan_pool(9) all the way down. go read the source, it's giving main character energy, iykyk 🌟

πŸ“¦ where this page comes from