sd_zbc_read_zones(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– sd_zbc_read_zones(9) πŸ’–

okay so bestie, welcome to the Kernel API Manual β€” yes we're in that part of the kernel, the SCSI zoned-storage part, and honestly? it's kind of iconic. sit down, hydrate, let's go 🫢


✨ NAME ✨

sd_zbc_read_zones β€” literally the function that reads your zone info and then updates the request queue. that's the whole vibe. πŸ’…


🌸 SYNOPSIS 🌸

int sd_zbc_read_zones (struct scsi_disk *sdkp , struct queue_limits *lim
, u8 buf[SD_BUF_SIZE] );

like, three args, one int back. no cap. ✨


πŸŽ€ ARGUMENTS πŸŽ€

  • sdkp β€” the SCSI disk pointer. your main character struct, fr fr. πŸ‘‘
  • lim β€” the queue limits that get read into. this is where the tea gets stored. πŸ“
  • buf β€” a 512 byte buffer used for storing SCSI command output. yes, exactly 512, don't @ me. πŸ’€

πŸ¦‹ DESCRIPTION πŸ¦‹

so what does it actually do? it reads zone information and updates the request queue zone characteristics β€” and it also updates the zoned device information inside *sdkp. two things, one function, we love a multitasker. πŸ’…

it gets called by sd_revalidate_disk before the gendisk capacity has been set. like, the capacity isn't ready yet at that point, so keep that in mind, okay? timing is everything. ⏰

ngl bestie, that ordering detail is the whole point β€” don't just skim past it. πŸ™ˆ

πŸ”₯ SEE ALSO πŸ”₯

kernel file stuff incoming, all of it, no skipping:

like a whole friend group of functions. go say hi to all of them. πŸ§šπŸ’œ


and that's the page!! πŸŽ€ this little beauty lives over in ./drivers/scsi, dated October 2026 β€” so like, future vibes only. slay, bye, go read some zones πŸ’–βœ¨πŸŒˆ

πŸ“¦ where this page comes from