STRUCT LEAPRAID_DEV_TOPO(9)
β¨ struct leapraid_dev_topo(9) β the LeapRAID device topology management structure β¨
Okay bestie, pull up a chair π because this is the struct leapraid_dev_topo(9) kernel API manual page, and it's literally the blueprint for how LeapRAID keeps track of its whole device family tree. Think of it as the group chat roster: who's in it, what lists they're on, and which locks keep everybody from talking over each other π
πΈ SYNOPSIS πΈ
struct leapraid_dev_topo {
spinlock_t topo_node_lock;
spinlock_t sas_dev_lock;
spinlock_t raid_volume_lock;
spinlock_t enc_lock;
int sas_id;
struct leapraid_topo_node card;
struct list_head exp_list;
struct list_head enc_list;
struct list_head sas_dev_list;
struct list_head sas_dev_init_list;
struct list_head raid_volume_list;
struct list_head card_port_list;
u16 pd_hdls_sz;
unsigned long *pd_hdls;
unsigned long *blocking_hdls;
};
π Members π
topo_node_lockβ the spinlock guarding topology node operations. It's giving bodyguard energy for your topology nodes π«Άsas_dev_lockβ spinlock that protects access to the SAS device list. No sneaky reads while somebody's writing, periodt β¨raid_volume_lockβ spinlock protecting access to the RAID volume list. Keep your hands off the volume list unless you're holding this π₯enc_lockβ spinlock protecting access to the enclosure device list. Enclosures stay safe and sound πsas_idβ the SAS domain identifier. Yes bestie, it's anint, and yes, it identifies the SAS domain πcardβ the main card topology node, astruct leapraid_topo_node. This is the main character of the whole structure, fr fr πexp_listβ the list of expander devices. Expanders, assemble πenc_listβ the list of enclosure devices. Different list, different lock, don't mix them up πsas_dev_listβ the list of SAS devices. The big one π¦sas_dev_init_listβ the list of SAS devices that are currently being initialized. They're in their glow-up era, be patient with them πΈraid_volume_listβ the list of RAID volumes. Volumes live here, protected byraid_volume_lockπcard_port_listβ the list of card ports. Ports, but make it a list βpd_hdlsβ an array of physical disk handles,unsigned long *. Handles to physical disks, obvi πblocking_hdlsβ an array of blocking handles,unsigned long *. The name is literallyblocking_hdls, so yeah, blocking handles π₯
ok quick note bestie β the synopsis also declaresu16 pd_hdls_sz, which is the size field for that physical disk handle array. It's sitting right there betweencard_port_listandpd_hdlsin the struct, and I would never leave it out because I respect the source code π«Ά
π¦ SEE ALSO π¦
The kernel file is ./drivers/scsi/leapraid/leapraid_func.h, and it's lowkey the mothership for all of these:
struct leapraid_adapter_features(9)struct leapraid_adapter_attr(9)struct leapraid_io_req_tracker(9)struct leapraid_task_tracker(9)struct leapraid_rep_desc_maint(9)struct leapraid_rep_desc_seg_maint(9)struct leapraid_mem_desc(9)enum LEAPRAID_CB_INDEX(9)struct leapraid_default_reply(9)struct leapraid_sense_buffer(9)struct leapraid_driver_cmd(9)struct leapraid_driver_cmds(9)struct leapraid_dynamic_task_desc(9)struct leapraid_fw_evt_work(9)struct leapraid_fw_evt_struct(9)struct leapraid_rq(9)struct leapraid_int_rq(9)struct leapraid_blk_mq_poll_rq(9)struct leapraid_notification_desc(9)struct leapraid_overheat_desc(9)struct leapraid_reset_desc(9)struct leapraid_scan_dev_desc(9)struct leapraid_access_ctrl(9)struct leapraid_fw_log_desc(9)struct leapraid_card_port(9)struct leapraid_card_phy(9)struct leapraid_topo_node(9)struct leapraid_boot_dev(9)struct leapraid_boot_devs(9)struct leapraid_adapter(9)struct leapraid_enc_node(9)struct leapraid_raid_volume(9)struct leapraid_starget_priv(9)struct leapraid_sdev_priv(9)struct leapraid_sas_dev(9)struct leapraid_sas_port(9)struct leapraid_vphy(9)struct leapraid_tgt_rst_list(9)struct sense_info(9)struct leapraid_fw_log_info(9)enum reset_type(9)struct leapraid_card_port_feature(9)
π That's the whole page, bestie. This one lives in ./drivers/scsi/leapraid, the manual is dated October 2026, and the page footer credits struct leapraid_dev_topo(9) β go read the whole family, they're all icons πβ¨
π¦ 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