STRUCT NILFS_BMAP_OPERATIONS(9)
π NAME
struct nilfs_bmap_operations β the bmap operation table, aka the little black book of function pointers that tells NILFS2 how to do block mapping stuff. Bestie, this is the vtable. It's giving "the whole personality of a bmap in one struct." π
β¨ SYNOPSIS β¨
struct nilfs_bmap_operations {
int (*bop_lookup)(const struct nilfs_bmap *, __u64, int, __u64 *);
int (*bop_lookup_contig)(const struct nilfs_bmap *, __u64, __u64 *,
unsigned int);
int (*bop_insert)(struct nilfs_bmap *, __u64, __u64);
int (*bop_delete)(struct nilfs_bmap *bmap, __u64 key, bool deform);
void (*bop_clear)(struct nilfs_bmap *);
int (*bop_propagate)(struct nilfs_bmap *, struct buffer_head *);
void (*bop_lookup_dirty_buffers)(struct nilfs_bmap *, struct
list_head *);
int (*bop_assign)(struct nilfs_bmap *, struct buffer_head **,
sector_t, union nilfs_binfo *);
int (*bop_mark)(struct nilfs_bmap *, __u64, int);
int (*bop_seek_key)(const struct nilfs_bmap *, __u64, __u64 *);
int (*bop_last_key)(const struct nilfs_bmap *, __u64 *);
};
Like, look at all those function pointers. Eleven of them. She's thorough. π
π¦ Members π¦
Okay so every single one of these does one little job, and together they run the whole show:
bop_lookupβ single block search operation. One block, one search, no cap. πbop_lookup_contigβ consecutive block search operation. Same energy but for a whole contiguous run, she's doing cardio. πββοΈbop_insertβ block insertion operation. New block bestie incoming. β¨bop_deleteβ block delete operation. Byeee, blocking you, literally. πbop_clearβ block mapping resource release operation. Cleaning up, closing tabs, releasing the resources, self-care fr fr. π§bop_propagateβ operation to propagate dirty state towards the mapping root. Dirty state travels upward, like gossip. πbop_lookup_dirty_buffersβ operation to collect dirty block buffers. Rounding up all the messy ones into a list. π«Άbop_assignβ disk block address assignment operation. Handing out addresses like a bouncer with a clipboard. πbop_markβ operation to mark in-use blocks as dirty for relocation by GC. GC = garbage collection, and she's tagging blocks so they get moved later. Marked. π·οΈbop_seek_keyβ find valid block key operation. Seek, and ye shall find. πbop_last_keyβ find last valid block key operation. The final boss key. β
π SEE ALSO π
Kernel file ./fs/nilfs2/bmap.h, plus these iconique friends:
union nilfs_bmap_ptr_req(9)struct nilfs_bmap_stats(9)struct nilfs_bmap(9)struct nilfs_bmap_store(9)
Go read ./fs/nilfs2/bmap.h if you want the full lore, iykyk. π
That's the whole page, bestie β no notes, ate and left absolutely no crumbs. This one comes straight out of ./fs/nilfs2 and it's dated October 2026, so likeβ¦ future vibes only. πβ¨π¦
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms