Go to the documentation of this file.
28 #ifndef _IXGBEVF_DEFINES_H_
29 #define _IXGBEVF_DEFINES_H_
32 #define IXGBE_DEV_ID_82599_VF 0x10ED
33 #define IXGBE_DEV_ID_X540_VF 0x1515
35 #define IXGBE_VF_IRQ_CLEAR_MASK 7
36 #define IXGBE_VF_MAX_TX_QUEUES 1
37 #define IXGBE_VF_MAX_RX_QUEUES 1
41 #define IXGBE_LINK_SPEED_1GB_FULL 0x0020
42 #define IXGBE_LINK_SPEED_10GB_FULL 0x0080
43 #define IXGBE_LINK_SPEED_100_FULL 0x0008
45 #define IXGBE_CTRL_RST 0x04000000
46 #define IXGBE_RXDCTL_ENABLE 0x02000000
47 #define IXGBE_TXDCTL_ENABLE 0x02000000
48 #define IXGBE_LINKS_UP 0x40000000
49 #define IXGBE_LINKS_SPEED_82599 0x30000000
50 #define IXGBE_LINKS_SPEED_10G_82599 0x30000000
51 #define IXGBE_LINKS_SPEED_1G_82599 0x20000000
52 #define IXGBE_LINKS_SPEED_100_82599 0x10000000
55 #define IXGBE_REQ_TX_DESCRIPTOR_MULTIPLE 8
56 #define IXGBE_REQ_RX_DESCRIPTOR_MULTIPLE 8
57 #define IXGBE_REQ_TX_BUFFER_GRANULARITY 1024
60 #define IXGBE_IVAR_ALLOC_VAL 0x80
62 #define IXGBE_VF_INIT_TIMEOUT 200
65 #define IXGBE_RXCTRL_RXEN 0x00000001
66 #define IXGBE_RXCTRL_DMBYPS 0x00000002
67 #define IXGBE_RXDCTL_ENABLE 0x02000000
68 #define IXGBE_RXDCTL_VME 0x40000000
69 #define IXGBE_RXDCTL_RLPMLMASK 0x00003FFF
70 #define IXGBE_RXDCTL_RLPML_EN 0x00008000
73 #define IXGBE_DCA_TXCTRL_TX_WB_RO_EN (1 << 11)
76 #define IXGBE_PSRTYPE_TCPHDR 0x00000010
77 #define IXGBE_PSRTYPE_UDPHDR 0x00000020
78 #define IXGBE_PSRTYPE_IPV4HDR 0x00000100
79 #define IXGBE_PSRTYPE_IPV6HDR 0x00000200
80 #define IXGBE_PSRTYPE_L2HDR 0x00001000
83 #define IXGBE_SRRCTL_BSIZEPKT_SHIFT 10
84 #define IXGBE_SRRCTL_RDMTS_SHIFT 22
85 #define IXGBE_SRRCTL_RDMTS_MASK 0x01C00000
86 #define IXGBE_SRRCTL_DROP_EN 0x10000000
87 #define IXGBE_SRRCTL_BSIZEPKT_MASK 0x0000007F
88 #define IXGBE_SRRCTL_BSIZEHDR_MASK 0x00003F00
89 #define IXGBE_SRRCTL_DESCTYPE_LEGACY 0x00000000
90 #define IXGBE_SRRCTL_DESCTYPE_ADV_ONEBUF 0x02000000
91 #define IXGBE_SRRCTL_DESCTYPE_HDR_SPLIT 0x04000000
92 #define IXGBE_SRRCTL_DESCTYPE_HDR_REPLICATION_LARGE_PKT 0x08000000
93 #define IXGBE_SRRCTL_DESCTYPE_HDR_SPLIT_ALWAYS 0x0A000000
94 #define IXGBE_SRRCTL_DESCTYPE_MASK 0x0E000000
97 #define IXGBE_RXD_STAT_DD 0x01
98 #define IXGBE_RXD_STAT_EOP 0x02
99 #define IXGBE_RXD_STAT_FLM 0x04
100 #define IXGBE_RXD_STAT_VP 0x08
101 #define IXGBE_RXDADV_NEXTP_MASK 0x000FFFF0
102 #define IXGBE_RXDADV_NEXTP_SHIFT 0x00000004
103 #define IXGBE_RXD_STAT_UDPCS 0x10
104 #define IXGBE_RXD_STAT_L4CS 0x20
105 #define IXGBE_RXD_STAT_IPCS 0x40
106 #define IXGBE_RXD_STAT_PIF 0x80
107 #define IXGBE_RXD_STAT_CRCV 0x100
108 #define IXGBE_RXD_STAT_VEXT 0x200
109 #define IXGBE_RXD_STAT_UDPV 0x400
110 #define IXGBE_RXD_STAT_DYNINT 0x800
111 #define IXGBE_RXD_STAT_TS 0x10000
112 #define IXGBE_RXD_STAT_SECP 0x20000
113 #define IXGBE_RXD_STAT_LB 0x40000
114 #define IXGBE_RXD_STAT_ACK 0x8000
115 #define IXGBE_RXD_ERR_CE 0x01
116 #define IXGBE_RXD_ERR_LE 0x02
117 #define IXGBE_RXD_ERR_PE 0x08
118 #define IXGBE_RXD_ERR_OSE 0x10
119 #define IXGBE_RXD_ERR_USE 0x20
120 #define IXGBE_RXD_ERR_TCPE 0x40
121 #define IXGBE_RXD_ERR_IPE 0x80
122 #define IXGBE_RXDADV_ERR_MASK 0xFFF00000
123 #define IXGBE_RXDADV_ERR_SHIFT 20
124 #define IXGBE_RXDADV_ERR_HBO 0x00800000
125 #define IXGBE_RXDADV_ERR_CE 0x01000000
126 #define IXGBE_RXDADV_ERR_LE 0x02000000
127 #define IXGBE_RXDADV_ERR_PE 0x08000000
128 #define IXGBE_RXDADV_ERR_OSE 0x10000000
129 #define IXGBE_RXDADV_ERR_USE 0x20000000
130 #define IXGBE_RXDADV_ERR_TCPE 0x40000000
131 #define IXGBE_RXDADV_ERR_IPE 0x80000000
132 #define IXGBE_RXD_VLAN_ID_MASK 0x0FFF
133 #define IXGBE_RXD_PRI_MASK 0xE000
134 #define IXGBE_RXD_PRI_SHIFT 13
135 #define IXGBE_RXD_CFI_MASK 0x1000
136 #define IXGBE_RXD_CFI_SHIFT 12
138 #define IXGBE_RXDADV_STAT_DD IXGBE_RXD_STAT_DD
139 #define IXGBE_RXDADV_STAT_EOP IXGBE_RXD_STAT_EOP
140 #define IXGBE_RXDADV_STAT_FLM IXGBE_RXD_STAT_FLM
141 #define IXGBE_RXDADV_STAT_VP IXGBE_RXD_STAT_VP
142 #define IXGBE_RXDADV_STAT_MASK 0x000FFFFF
143 #define IXGBE_RXDADV_STAT_FCEOFS 0x00000040
144 #define IXGBE_RXDADV_STAT_FCSTAT 0x00000030
145 #define IXGBE_RXDADV_STAT_FCSTAT_NOMTCH 0x00000000
146 #define IXGBE_RXDADV_STAT_FCSTAT_NODDP 0x00000010
147 #define IXGBE_RXDADV_STAT_FCSTAT_FCPRSP 0x00000020
148 #define IXGBE_RXDADV_STAT_FCSTAT_DDP 0x00000030
150 #define IXGBE_RXDADV_RSSTYPE_MASK 0x0000000F
151 #define IXGBE_RXDADV_PKTTYPE_MASK 0x0000FFF0
152 #define IXGBE_RXDADV_PKTTYPE_MASK_EX 0x0001FFF0
153 #define IXGBE_RXDADV_HDRBUFLEN_MASK 0x00007FE0
154 #define IXGBE_RXDADV_RSCCNT_MASK 0x001E0000
155 #define IXGBE_RXDADV_RSCCNT_SHIFT 17
156 #define IXGBE_RXDADV_HDRBUFLEN_SHIFT 5
157 #define IXGBE_RXDADV_SPLITHEADER_EN 0x00001000
158 #define IXGBE_RXDADV_SPH 0x8000
160 #define IXGBE_RXD_ERR_FRAME_ERR_MASK ( \
164 IXGBE_RXD_ERR_OSE | \
167 #define IXGBE_RXDADV_ERR_FRAME_ERR_MASK ( \
168 IXGBE_RXDADV_ERR_CE | \
169 IXGBE_RXDADV_ERR_LE | \
170 IXGBE_RXDADV_ERR_PE | \
171 IXGBE_RXDADV_ERR_OSE | \
172 IXGBE_RXDADV_ERR_USE)
174 #define IXGBE_TXD_POPTS_IXSM 0x01
175 #define IXGBE_TXD_POPTS_TXSM 0x02
176 #define IXGBE_TXD_CMD_EOP 0x01000000
177 #define IXGBE_TXD_CMD_IFCS 0x02000000
178 #define IXGBE_TXD_CMD_IC 0x04000000
179 #define IXGBE_TXD_CMD_RS 0x08000000
180 #define IXGBE_TXD_CMD_DEXT 0x20000000
181 #define IXGBE_TXD_CMD_VLE 0x40000000
182 #define IXGBE_TXD_STAT_DD 0x00000001
238 #define IXGBE_ADVTXD_DTYP_MASK 0x00F00000
239 #define IXGBE_ADVTXD_DTYP_CTXT 0x00200000
240 #define IXGBE_ADVTXD_DTYP_DATA 0x00300000
241 #define IXGBE_ADVTXD_DCMD_EOP IXGBE_TXD_CMD_EOP
242 #define IXGBE_ADVTXD_DCMD_IFCS IXGBE_TXD_CMD_IFCS
243 #define IXGBE_ADVTXD_DCMD_RS IXGBE_TXD_CMD_RS
244 #define IXGBE_ADVTXD_DCMD_DEXT IXGBE_TXD_CMD_DEXT
245 #define IXGBE_ADVTXD_DCMD_VLE IXGBE_TXD_CMD_VLE
246 #define IXGBE_ADVTXD_DCMD_TSE 0x80000000
247 #define IXGBE_ADVTXD_STAT_DD IXGBE_TXD_STAT_DD
248 #define IXGBE_ADVTXD_TUCMD_IPV4 0x00000400
249 #define IXGBE_ADVTXD_TUCMD_IPV6 0x00000000
250 #define IXGBE_ADVTXD_TUCMD_L4T_UDP 0x00000000
251 #define IXGBE_ADVTXD_TUCMD_L4T_TCP 0x00000800
252 #define IXGBE_ADVTXD_TUCMD_L4T_SCTP 0x00001000
253 #define IXGBE_ADVTXD_IDX_SHIFT 4
254 #define IXGBE_ADVTXD_CC 0x00000080
255 #define IXGBE_ADVTXD_POPTS_SHIFT 8
256 #define IXGBE_ADVTXD_POPTS_IXSM (IXGBE_TXD_POPTS_IXSM << \
257 IXGBE_ADVTXD_POPTS_SHIFT)
258 #define IXGBE_ADVTXD_POPTS_TXSM (IXGBE_TXD_POPTS_TXSM << \
259 IXGBE_ADVTXD_POPTS_SHIFT)
260 #define IXGBE_ADVTXD_PAYLEN_SHIFT 14
261 #define IXGBE_ADVTXD_MACLEN_SHIFT 9
262 #define IXGBE_ADVTXD_VLAN_SHIFT 16
263 #define IXGBE_ADVTXD_L4LEN_SHIFT 8
264 #define IXGBE_ADVTXD_MSS_SHIFT 16
268 #define IXGBE_EITR_CNT_WDIS 0x80000000
269 #define IXGBE_MAX_EITR 0x00000FF8
270 #define IXGBE_MIN_EITR 8
273 #define IXGBE_ERR_INVALID_MAC_ADDR -1
274 #define IXGBE_ERR_RESET_FAILED -2
275 #define IXGBE_ERR_INVALID_ARGUMENT -3