drbd_queue_bitmap_io(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’« drbd_queue_bitmap_io(9) πŸ’«

okay so bestie, welcome to the drbd_queue_bitmap_io(9) page from the Kernel API Manual β€” this is the one that queues up an IO operation across the whole bitmap, and honestly? kind of iconic of it. πŸŽ€


✨ NAME ✨

drbd_queue_bitmap_io β€” the function that queues an IO operation on the entire bitmap, no cap. 🌈


πŸ¦‹ SYNOPSIS πŸ¦‹

void drbd_queue_bitmap_io (struct drbd_device *device , int
(*io_fn)(struct drbd_device *, struct drbd_peer_device *) , void
(*done)(struct drbd_device *, int) , char *why , enum bm_flag flags ,
struct drbd_peer_device *peer_device );

like, that's the whole signature, copy it exactly bestie, do not come for me about the line breaks 😭


🌸 ARGUMENTS 🌸

  • device β€” the DRBD device. the main character of this whole situation tbh πŸ‘‘
  • io_fn β€” the IO callback. this is the one that gets called when bitmap IO is actually possible, so it's lowkey the star of the show ⭐
  • done β€” the callback that's called after the bitmap IO was performed. the afterparty, if you will πŸŽ‰
  • why β€” descriptive text explaining the reason for doing the IO. literally just your receipts, keep them πŸ’…
  • flags β€” bitmap flags. enum bm_flag energy 🧚
  • peer_device β€” the peer DRBD device. every main character needs their bestie 🫢

πŸ’œ DESCRIPTION πŸ’œ

so here's the vibe: while IO on the bitmap is happening, we freeze application IO, which means we make sure drbd_set_out_of_sync can not be called. yeah. that's the whole point. πŸ”₯

⚠️ okay this part matters, bestie, listen up: this function MAY ONLY be called from worker context. like, that's not a suggestion, that's the rule. and it MUST NOT be used while a previous such work is still pending! no stacking, no overlapping, none of that πŸ™ˆ

and for the nerdy details: its worker function encloses the call of io_fn by get_ldev and put_ldev. so io_fn is literally wrapped up all cozy in there πŸŽ€βœ¨


πŸ’€ SEE ALSO πŸ’€

all the related lore, in the kernel file ./drivers/block/drbd/drbd_main.c:


and that's the whole page, bestie!! it lives in ./drivers/block/drbd, dated October 2026 β€” so yeah, mark your calendar, screenshot it, send it to the group chat, this one's a keeper πŸ’–βœ¨πŸ¦‹πŸ’…

mwah, go freeze some application IO responsibly πŸ“

πŸ“¦ where this page comes from