STRUCT PDS_CORE_Q_INIT_CMD(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

🌸 struct pds_core_q_init_cmd β€” Queue init command 🌸

okay bestie, welcome to the Kernel API Manual, section 9 β€” this is the page for struct pds_core_q_init_cmd, aka the lil love letter you send to the firmware when you want a queue born πŸ’– it's the queue init command, and it's genuinely so iconic for a struct that's basically a form to fill out.


✨ SYNOPSIS ✨

no cap, this is the whole shape of it. copy it exactly, don't freestyle 🫢

struct pds_core_q_init_cmd {
    u8 opcode;
    u8 type;
    __le16 client_id;
    u8 ver;
    u8 rsvd[3];
    __le32 index;
    __le16 pid;
    __le16 intr_index;
    __le16 flags;
  #define PDS_CORE_QINIT_F_IRQ    0x01    ;
  #define PDS_CORE_QINIT_F_ENA    0x02    ;
    u8 cos;
  #define PDS_CORE_QSIZE_MIN_LG2  2;
  #define PDS_CORE_QSIZE_MAX_LG2  12;
    u8 ring_size;
    __le64 ring_base;
    __le64 cq_ring_base;
 };

πŸŽ€ Members πŸŽ€

these are the fields, and yes we're doing all of them, nobody's getting skipped πŸ’…

  • opcode β€” the opcode, and it's PDS_AQ_CMD_Q_INIT. that's literally it, that's the vibe check it has to pass ✨
  • type β€” logical queue type. like, which flavor of queue are we even doing here πŸ¦‹
  • client_id β€” client identifier. tells the firmware who's asking, bestie, so it knows who to text back πŸ“±
  • ver β€” queue type version. versioning! we love a struct that respects versioning πŸ™ˆ
  • rsvd β€” word boundary padding. it's filler, it's decor, it's doing absolutely nothing and we still respect it πŸŽ€
  • index β€” the (LIF, qtype) relative admin queue index. keyed off both the LIF and the qtype, so it's giving very specific πŸ’œ
  • pid β€” process ID.
  • intr_index β€” interrupt control register index, or Event queue index. one field, two possible jobs β€” main character energy fr fr πŸ‘‘
  • flags β€” the bit flags, and there are two of them:
    • IRQ β€” Interrupt requested on completion.
    • ENA β€” Enable the queue. If ENA=0 the queue is initialized but remains disabled, to be later enabled with the Queue Enable command. If ENA=1, then queue is initialized and then enabled.
  • cos β€” class of service for this queue. fancy ✨
  • ring_size β€” Queue ring size, encoded as a log2(size), in number of descriptors. The actual ring size is (1 << ring_size). For example, to select a ring size of 64 descriptors write ring_size = 6. The minimum ring_size value is 2 for a ring of 4 descriptors. The maximum ring_size value is 12 for a ring of 4k descriptors. Values of ring_size <2 and >12 are reserved.
⚠️ ok this one matters: ring_size is a log2, not a count. do not put 64 in there thinking you're clever, put 6. and stay inside 2–12 because <2 and >12 are reserved β€” reserved is just the kernel's polite way of saying "girl don't" 😭
  • ring_base β€” Queue ring base address.
  • cq_ring_base β€” Completion queue ring base address.

πŸ”₯ SEE ALSO πŸ”₯

the whole extended universe, bestie β€” the kernel file lives at ./include/linux/pds/pds_adminq.h, and here's every sibling struct/friend this page points you at πŸ’–

  • pds_core_notifyq_event(9)
  • struct pds_core_link_change_event(9)
  • struct pds_core_reset_event(9)
  • struct pds_core_client_event(9)
  • struct pds_core_notifyq_cmd(9)
  • struct pds_core_client_reg_cmd(9)
  • struct pds_core_client_reg_comp(9)
  • struct pds_core_client_unreg_cmd(9)
  • struct pds_core_client_request_cmd(9)
  • enum pds_core_logical_qtype(9)
  • union pds_core_lif_config(9)
  • struct pds_core_lif_status(9)
  • struct pds_core_lif_info(9)
  • struct pds_core_lif_identity(9)
  • struct pds_core_lif_identify_cmd(9)
  • struct pds_core_lif_identify_comp(9)
  • struct pds_core_lif_init_cmd(9)
  • struct pds_core_lif_init_comp(9)
  • struct pds_core_lif_reset_cmd(9)
  • enum pds_core_lif_attr(9)
  • struct pds_core_lif_setattr_cmd(9)
  • struct pds_core_lif_setattr_comp(9)
  • struct pds_core_lif_getattr_cmd(9)
  • struct pds_core_lif_getattr_comp(9)
  • struct pds_core_q_identity(9)
  • struct pds_core_q_identify_cmd(9)
  • struct pds_core_q_identify_comp(9)
  • struct pds_core_q_init_comp(9)
  • struct pds_vdpa_cmd(9)
  • struct pds_vdpa_init_cmd(9)
  • struct pds_vdpa_ident(9)
  • struct pds_vdpa_ident_cmd(9)
  • struct pds_vdpa_status_cmd(9)
  • enum pds_vdpa_attr(9)
  • struct pds_vdpa_setattr_cmd(9)
  • struct pds_vdpa_vq_init_cmd(9)
  • struct pds_vdpa_vq_init_comp(9)
  • struct pds_vdpa_vq_reset_cmd(9)
  • struct pds_vdpa_vq_reset_comp(9)
  • struct pds_vdpa_set_features_cmd(9)
  • struct pds_lm_cmd(9)
  • struct pds_lm_state_size_cmd(9)
  • struct pds_lm_state_size_comp(9)
  • struct pds_lm_suspend_cmd(9)
  • struct pds_lm_suspend_status_cmd(9)
  • struct pds_lm_resume_cmd(9)
  • struct pds_lm_sg_elem(9)
  • struct pds_lm_save_cmd(9)
  • struct pds_lm_restore_cmd(9)
  • union pds_lm_dev_state(9)
  • struct pds_lm_dirty_region_info(9)
  • struct pds_lm_dirty_status_cmd(9)
  • enum pds_lm_dirty_bmp_type(9)
  • struct pds_lm_dirty_status_comp(9)
  • struct pds_lm_dirty_enable_cmd(9)
  • struct pds_lm_dirty_disable_cmd(9)
  • struct pds_lm_dirty_seq_ack_cmd(9)
  • struct pds_lm_host_vf_status_cmd(9)
  • struct pds_fwctl_cmd(9)
  • struct pds_fwctl_comp(9)
  • struct pds_fwctl_ident_cmd(9)
  • struct pds_fwctl_ident(9)
  • struct pds_fwctl_query_cmd(9)
  • struct pds_fwctl_query_comp(9)
  • struct pds_fwctl_query_data_endpoint(9)
  • struct pds_fwctl_query_data_operation(9)
  • struct pds_fwctl_query_data(9)
  • struct pds_fwctl_rpc_cmd(9)
  • struct pds_sg_elem(9)
  • struct pds_fwctl_rpc_comp(9)

that's the whole page, bestie, you ate it up πŸ’… go forth and initialize your queues responsibly. and for the receipts: this came out of ./include/linux/pds, dated October 2026, and it's page struct pds_core_q_init_cmd(9) of the Kernel API Manual β€” mwah, stan a well-documented struct πŸ’–πŸŽ€βœ¨

πŸ“¦ where this page comes from