sd_group_number(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸŽ€ sd_group_number(9) β€” like, the kernel API manual, bestie πŸŽ€

okay so first things first: this is a page from the Kernel API Manual, section 9, and the function it's hyping up is called sd_group_number. Buckle up buttercup, it's a short one but it's iconic πŸ’…


✨ NAME ✨

sd_group_number β€” literally just computes the GROUP NUMBER field. that's it. that's the whole job 🫢


🌸 SYNOPSIS 🌸

u8 sd_group_number (struct scsi_cmnd *cmd );

yes bestie, it returns a u8, and yes, it takes exactly one argument. no plot twist πŸ¦‹


πŸ’– ARGUMENTS πŸ’–

  • cmd β€” the SCSI command you're handing over, aka the thing you want the value of the six-bit GROUP NUMBER field computed for. six bits. tiny but mighty ✨

πŸ‘‘ DESCRIPTION πŸ‘‘

okay so here's the tea, straight from SBC-5 r05, and I'm citing my source because I'm a scholar:

https://www.t10.org/cgi-bin/ac.pl?t=ff=sbc5r05.pdf

the GROUP NUMBER field maps to relative lifetimes like this 🌈:

  • 0 β€” no relative lifetime. like, none. zero. the void πŸ’€
  • 1 β€” shortest relative lifetime ⚑
  • 2 β€” second shortest relative lifetime πŸ“
  • 3 – 0x3d β€” intermediate relative lifetimes, the whole mushy middle, the group chat of values 🫢
  • 0x3e β€” second longest relative lifetime 🌸
  • 0x3f β€” longest relative lifetime, the final boss, main character energy πŸ‘‘

that's the entire mapping. no cap. 🧚


πŸ”₯ SEE ALSO πŸ”₯

the kernel file lives at ./drivers/scsi/sd.c, and honestly the whole friend group shows up here:

go read all of them, i'll wait πŸ’œ


and that's the page!! sign-off time: this lil masterpiece comes to you from the ./drivers/scsi directory, dated October 2026, and it's giving Kernel API Manual realness. slay, bye πŸ’…βœ¨πŸŽ€

πŸ“¦ where this page comes from