STRUCT TGT_DEV_VD(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct tgt_dev_vd(9) β€” the kernel API manual, but make it make sense

okay so bestie, we're in the <pink>Kernel API Manual</pink> today and the main character is struct tgt_dev_vd. Say it with me: tgt_dev_vd. It's the little sidecar of virtual-device-specific info, cached straight out of the data the firmware hands you. That's the whole vibe. πŸŽ€


✨ NAME ✨

struct tgt_dev_vd β€” virtual device specific information cached from firmware given data

Like, the firmware already told us stuff, and this struct is where we keep the receipts. πŸ’–


πŸ¦‹ SYNOPSIS πŸ¦‹

struct tgt_dev_vd {
    u8 state;
    u8 tg_qd_reduction;
    u16 tg_id;
    u32 tg_high;
    u32 tg_low;
    u8 abort_to;
    u8 reset_to;
    struct mpi3mr_throttle_group_info *tg;
 };

no cap, that's the whole thing. Nine-ish lines of pure potential. ✨


🌸 Members 🌸

okay so let's do a little meet-the-cast moment, because every field here is a main character in its own right:

  • state β€” State of the VD. That's it, that's the field. It's giving "vibes check" but officially. πŸ‘‘
  • tg_qd_reduction β€” Queue Depth reduction, measured in units of 10%. So it's a percentage-adjacent number, not the percentage itself β€” don't come for me, that's literally what the page says. πŸ’…
  • tg_id β€” the VD's throttle group ID. yep. that's the ID of the throttle group. iconic.
  • tg β€” a pointer to mpi3mr_throttle_group_info. Pointer bestie, so be normal about it. 🫢
also lowkey the struct has tg_high, tg_low, abort_to and reset_to hanging out in there, and the Members list does not spell them out β€” so I'm not gonna make stuff up. if you need the tea on those, the header is right there. iykyk πŸ“

πŸ”₯ SEE ALSO πŸ”₯

the friend group is huge, strap in. All of these live in the kernel file ./drivers/scsi/mpi3mr/mpi3mr.h:

  • struct mpi3mr_nvme_pt_sge(9)
  • struct mpi3mr_buf_map(9)
  • struct mpi3mr_compimg_ver(9)
  • struct segments(9)
  • struct op_req_qinfo(9)
  • struct op_reply_qinfo(9)
  • struct mpi3mr_intr_info(9)
  • struct mpi3mr_throttle_group_info(9)
  • struct mpi3mr_hba_port(9)
  • struct mpi3mr_sas_port(9)
  • struct mpi3mr_sas_phy(9)
  • struct mpi3mr_sas_node(9)
  • struct mpi3mr_enclosure_node(9)
  • struct tgt_dev_sas_sata(9)
  • struct tgt_dev_pcie(9)
  • union _form_spec_inf(9)
  • struct mpi3mr_tgt_dev(9)
  • mpi3mr_tgtdev_get(9)
  • mpi3mr_free_tgtdev(9)
  • mpi3mr_tgtdev_put(9)
  • struct mpi3mr_stgt_priv_data(9)
  • struct mpi3mr_drv_cmd(9)
  • union mpi3mr_trigger_data(9)
  • struct trigger_event_data(9)
  • struct diag_buffer_desc(9)
  • struct dma_memory_desc(9)
  • struct chain_element(9)
  • struct scmd_priv(9)
  • struct mpi3mr_ioc(9)
  • struct mpi3mr_fwevt(9)
  • struct delayed_dev_rmhs_node(9)
  • struct delayed_evt_ack_node(9)

like I said. the whole friend group. go say hi, they don't bite. 🌈


okay that's the page!! mwah πŸ’‹ go read the header, drink some water, and remember: cached firmware data is still data, and you're doing great.

πŸ¦‹ this little love letter comes to you from ./drivers/scsi/mpi3mr, dated October 2026 β€” that's the source and the date, both accounted for, periodt. πŸ’œ

πŸ“¦ where this page comes from