STRUCT VIRTCHNL2_GET_PTYPE_INFO(9)
π struct virtchnl2_get_ptype_info β Kernel API Manual β¨
okay bestie, welcome to the struct virtchnl2_get_ptype_info page π this one lives in the Kernel API Manual and it's all about packet type info, so grab a strawberry drink π and let's get into it.
πΈ NAME πΈ
struct virtchnl2_get_ptype_info β Packet type info. literally that's the whole vibe, it's giving "packet type info" π
β¨ SYNOPSIS β¨
struct virtchnl2_get_ptype_info {
__le16 start_ptype_id;
__le16 num_ptypes;
__le32 pad;
};
that's the whole struct, no cap π«Ά
π Members π
start_ptype_idβ your starting ptype ID. like where the party begins πnum_ptypesβ how many packet types you want, counting fromstart_ptype_id. it's giving "how many friends am I bringing" π₯padβ padding for future extensions. it's reserved, it's just sitting there looking cute, leave it alone π
π¦ Description π¦
so here's the tea β the total number of supported packet types depends entirely on the descriptor type, okurrr:
- flex descriptor β it's
1024(that's a 10-bit ptype) β - base descriptor β it's
256(that's an 8-bit ptype) πΈ
you send this message to the CP by populating the 'start_ptype_id' and the 'num_ptypes'. then CP responds with theβ¦ okay bestie, the source text for this bit got a little chewed up by the manpage machine π so I'm giving it to you exactly as it came, no edits, no guessing:
"CP responds with the are added at the end of the 'virtchnl2_get_ptype_info' message (Note: There is no specific field for the ptypes but are added at the end of the ptype info message. PF/VF is expected to extract the ptypes accordingly. Reason for doing this is because compiler doesn't allow nested flexible array fields)."
and here's the next part, also verbatim because the mangling is real π:
"If all the ptypes don't fit into one mailbox buffer, CP splits the ptype info into multiple messages, where each message will have its own updating all the ptype information extracted from the package (the number of ptypes extracted might be less than what PF/VF expects), it will append a dummy ptype (which has'ptype_id_10'of'struct virtchnl2_ptype'as0xFFFF) to the ptype array."
the genuinely important bits in there, bestie, so you don't miss them π:
- if all the ptypes don't fit into one mailbox buffer, CP splits the ptype info into multiple messages π
- each message has its own thing going on
- the number of ptypes extracted might be less than what PF/VF expects
- in that case it appends a dummy ptype β and that dummy has
'ptype_id_10'of'struct virtchnl2_ptype'set to0xFFFFπ― - and yeah, that's because the compiler doesn't allow nested flexible array fields. iconic compiler behaviour, honestly π
PF/VF is expected to receive multiple VIRTCHNL2_OP_GET_PTYPE_INFO messages. like, plural. buckle up π§
this whole thing is associated with VIRTCHNL2_OP_GET_PTYPE_INFO. periodt π
π SEE ALSO π
okay this list is LONG and it ATE, every single one of these is a friend of ours in Kernel file ./include/linux/net/intel/virtchnl2.h π«Ά:
enum virtchnl2_vport_type(9)enum virtchnl2_queue_model(9)enum virtchnl2_action_types(9)enum virtchnl2_txq_sched_mode(9)enum virtchnl2_rxq_flags(9)enum virtchnl2_mac_addr_type(9)struct virtchnl2_edt_caps(9)struct virtchnl2_version_info(9)struct virtchnl2_get_capabilities(9)struct virtchnl2_queue_reg_chunk(9)struct virtchnl2_queue_reg_chunks(9)enum virtchnl2_vport_flags(9)struct virtchnl2_create_vport(9)struct virtchnl2_vport(9)struct virtchnl2_txq_info(9)struct virtchnl2_config_tx_queues(9)struct virtchnl2_rxq_info(9)struct virtchnl2_config_rx_queues(9)struct virtchnl2_add_queues(9)struct virtchnl2_vector_chunk(9)struct virtchnl2_vector_chunks(9)struct virtchnl2_alloc_vectors(9)struct virtchnl2_rss_lut(9)struct virtchnl2_rss_hash(9)struct virtchnl2_sriov_vfs_info(9)struct virtchnl2_ptype(9)struct virtchnl2_vport_stats(9)struct virtchnl2_event(9)struct virtchnl2_rss_key(9)struct virtchnl2_queue_chunk(9)struct virtchnl2_del_ena_dis_queues(9)struct virtchnl2_queue_vector(9)struct virtchnl2_queue_vector_maps(9)struct virtchnl2_loopback(9)struct virtchnl2_mac_addr_list(9)struct virtchnl2_promisc_info(9)enum virtchnl2_ptp_caps(9)struct virtchnl2_ptp_clk_reg_offsets(9)struct virtchnl2_ptp_cross_time_reg_offsets(9)struct virtchnl2_ptp_clk_adj_reg_offsets(9)struct virtchnl2_ptp_tx_tstamp_latch_caps(9)struct virtchnl2_ptp_get_vport_tx_tstamp_caps(9)struct virtchnl2_ptp_get_caps(9)struct virtchnl2_ptp_tx_tstamp_latch(9)struct virtchnl2_ptp_get_vport_tx_tstamp_latches(9)struct virtchnl2_ptp_get_dev_clk_time(9)struct virtchnl2_ptp_get_cross_time(9)struct virtchnl2_ptp_set_dev_clk_time(9)struct virtchnl2_ptp_adj_dev_clk_fine(9)struct virtchnl2_ptp_adj_dev_clk_time(9)struct virtchnl2_mem_region(9)struct virtchnl2_get_lan_memory_regions(9)struct virtchnl2_proto_hdr(9)struct virtchnl2_proto_hdrs(9)struct virtchnl2_rule_action(9)struct virtchnl2_rule_action_set(9)struct virtchnl2_flow_rule(9)struct virtchnl2_flow_rule_info(9)struct virtchnl2_flow_rule_add_del(9)
and that's the page, bestie!! ππβ¨
fr fr this one shipped from ./include/linux/net/intel back in October 2026, so shoutout to the source and the date β mwah, love u, bye ππ¦πΈ
π¦ 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