18 #ifndef _AVF_VIRTCHNL_H_ 19 #define _AVF_VIRTCHNL_H_ 21 #define VIRTCHNL_VERSION_MAJOR 1 22 #define VIRTCHNL_VERSION_MINOR 1 24 #define foreach_avf_promisc_flags \ 25 _(0, UNICAST_PROMISC, "unicast") \ 26 _(1, MULTICAST_PROMISC, "multicast") 30 #define _(a, b, c) FLAG_VF_ ##b = (1 << a), 35 #define AVFINT_DYN_CTLN(x) (0x00003800 + (0x4 * x)) 36 #define AVFINT_ICR0 0x00004800 37 #define AVFINT_ICR0_ENA1 0x00005000 38 #define AVFINT_DYN_CTL0 0x00005C00 39 #define AVF_ARQBAH 0x00006000 40 #define AVF_ATQH 0x00006400 41 #define AVF_ATQLEN 0x00006800 42 #define AVF_ARQBAL 0x00006C00 43 #define AVF_ARQT 0x00007000 44 #define AVF_ARQH 0x00007400 45 #define AVF_ATQBAH 0x00007800 46 #define AVF_ATQBAL 0x00007C00 47 #define AVF_ARQLEN 0x00008000 48 #define AVF_ATQT 0x00008400 49 #define AVFGEN_RSTAT 0x00008800 50 #define AVF_QTX_TAIL(q) (0x00000000 + (0x4 * q)) 51 #define AVF_QRX_TAIL(q) (0x00002000 + (0x4 * q)) 53 #define AVF_AQ_F_DD (1 << 0) 54 #define AVF_AQ_F_CMP (1 << 1) 55 #define AVF_AQ_F_ERR (1 << 2) 56 #define AVF_AQ_F_VFE (1 << 3) 57 #define AVF_AQ_F_LB (1 << 9) 58 #define AVF_AQ_F_RD (1 << 10) 59 #define AVF_AQ_F_VFC (1 << 11) 60 #define AVF_AQ_F_BUF (1 << 12) 61 #define AVF_AQ_F_SI (1 << 13) 62 #define AVF_AQ_F_EI (1 << 14) 63 #define AVF_AQ_F_FE (1 << 15) 66 #define foreach_virtchnl_op \ 70 _(3, GET_VF_RESOURCES) \ 71 _(4, CONFIG_TX_QUEUE) \ 72 _(5, CONFIG_RX_QUEUE) \ 73 _(6, CONFIG_VSI_QUEUES) \ 74 _(7, CONFIG_IRQ_MAP) \ 76 _(9, DISABLE_QUEUES) \ 81 _(14, CONFIG_PROMISCUOUS_MODE) \ 88 _(21, CONFIG_IWARP_IRQ_MAP) \ 89 _(22, RELEASE_IWARP_IRQ_MAP) \ 90 _(23, CONFIG_RSS_KEY) \ 91 _(24, CONFIG_RSS_LUT) \ 92 _(25, GET_RSS_HENA_CAPS) \ 94 _(27, ENABLE_VLAN_STRIPPING) \ 95 _(28, DISABLE_VLAN_STRIPPING) \ 96 _(29, REQUEST_QUEUES) \ 97 _(30, ENABLE_CHANNELS) \ 98 _(31, DISABLE_CHANNELS) \ 99 _(32, ADD_CLOUD_FILTER) \ 100 _(33, DEL_CLOUD_FILTER) 105 #define _(v,n) VIRTCHNL_OP_##n = v, 123 #define foreach_avf_vf_cap_flag \ 124 _( 0, OFFLOAD_L2, "l2") \ 125 _( 1, OFFLOAD_IWARP, "iwarp") \ 126 _( 2, OFFLOAD_RSVD, "rsvd") \ 127 _( 3, OFFLOAD_RSS_AQ, "rss-aq") \ 128 _( 4, OFFLOAD_RSS_REG, "rss-reg") \ 129 _( 5, OFFLOAD_WB_ON_ITR, "wb-on-itr") \ 130 _( 6, OFFLOAD_REQ_QUEUES, "req-queues") \ 131 _( 7, CAP_ADV_LINK_SPEED, "adv-link-speed") \ 132 _(16, OFFLOAD_VLAN, "vlan") \ 133 _(17, OFFLOAD_RX_POLLING, "rx-polling") \ 134 _(18, OFFLOAD_RSS_PCTYPE_V2, "rss-pctype-v2") \ 135 _(19, OFFLOAD_RSS_PF, "rss-pf") \ 136 _(20, OFFLOAD_ENCAP, "encap") \ 137 _(21, OFFLOAD_ENCAP_CSUM, "encap-csum") \ 138 _(22, OFFLOAD_RX_ENCAP_CSUM, "rx-encap-csum") \ 139 _(23, OFFLOAD_ADQ, "offload-adq") 143 #define _(a, b, c) VIRTCHNL_VF_##b = (1 << a), 167 u8 default_mac_addr[6];
182 #define foreach_virtchnl_event_code \ 185 _(2, RESET_IMPENDING) \ 186 _(3, PF_DRIVER_CLOSE) 190 #define _(a,b) VIRTCHNL_EVENT_##b = (a), 195 #define foreach_virtchnl_link_speed \ 196 _(0, 2_5GB, "2.5 Gbps") \ 197 _(1, 100MB, "100 Mbps") \ 198 _(2, 1GB, "1 Gbps") \ 199 _(3, 10GB, "10 Gbps") \ 200 _(4, 40GB, "40 Gbps") \ 201 _(5, 20GB, "20 Gbps") \ 202 _(6, 25GB, "25 Gbps") \ 208 #define _(a,b,c) VIRTCHNL_LINK_SPEED_##b = (1 << a), 357 #define foreach_virtchnl_eth_stats \ 363 _(rx_unknown_protocol)\
u8 pad[3]
log2 (size of the packing page block)
#define foreach_avf_vf_cap_flag
virtchnl_vsi_type_t vsi_type
#define foreach_virtchnl_eth_stats
#define foreach_virtchnl_event_code
virtchnl_link_speed_t link_speed
#define foreach_avf_promisc_flags
virtchnl_status_code_t v_retval
STATIC_ASSERT_SIZEOF(virtchnl_pf_event_t, 16)
#define foreach_virtchnl_link_speed
virtchnl_event_codes_t event
#define foreach_virtchnl_op