STRUCT SRPT_PORT_ID(9)
β¨ struct srpt_port_id(9) β¨
okay bestie, we're diving into the Kernel API Manual for struct srpt_port_id and honestly? it's giving "small but mighty" π
this is the LIO RDMA port info situation, and we're gonna break it down so you can slay your kernel understanding fr fr.
π NAME π
struct srpt_port_id β literally just the LIO RDMA port information, no cap. it's the struct that holds all the deets about a single (port, name) pair. iconic behavior tbh.
πΈ SYNOPSIS πΈ
okay so here's the actual structure, look at her:
struct srpt_port_id {
struct mutex mutex;
struct list_head tpg_list;
struct se_wwn wwn;
char name[64];
};
that's it. that's the whole vibe. four members, each one doing its absolute thing. periodt.
π Members π
let's meet the cast, bestie β every single one matters:
mutexβ this is the bodyguard π«Ά it protectstpg_listchanges. like, don't touch the list without going through the mutex first, that's the rule.tpg_listβ all the TPGs chillin' here, associated with the RDMA port name. this is the main character list ngl.wwnβ the WWN associated with the RDMA port name. world wide name energy, we love to see it β¨nameβ the ASCII representation of the port name. it's achar[64]so it can hold a whole 64 characters of pure port-name identity π
π¦ Description π¦
okay so here's the tea: multiple sysfs directories can be associated with a single RDMA port. wild, right? π and this data structure? it represents a single (port, name) pair. so like, one struct = one pairing, and that's the whole point. it's giving "organized chaos" and honestly we're obsessed.
π SEE ALSO π
if you wanna keep the lore going, check these out β every single one, no skipping bestie:
- Kernel file
./drivers/infiniband/ulp/srpt/ib_srpt.h enum srpt_command_state(9)struct srpt_ioctx(9)struct srpt_recv_ioctx(9)struct srpt_send_ioctx(9)enum rdma_ch_state(9)struct srpt_rdma_ch(9)struct srpt_nexus(9)struct srpt_port_attrib(9)struct srpt_tpg(9)struct srpt_port(9)struct srpt_device(9)
like a whole friend group of structs and enums, and they all ate π₯
and that's the whole page, bestie π courtesy of the kernel squad over in ./drivers/infiniband/ulp/srpt, last touched October 2026 β go off and read those sysfs directories with confidence now πβ¨
π¦ 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