1 /* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(c) 2017 Cavium, Inc
5 #ifndef __OCTEONTX_PKI_VAR_H__
6 #define __OCTEONTX_PKI_VAR_H__
8 #include <rte_byteorder.h>
10 #define OCTTX_PACKET_WQE_SKIP 128
11 #define OCTTX_PACKET_FIRST_SKIP 240
12 #define OCTTX_PACKET_LATER_SKIP 128
15 typedef union octtx_wqe_s
{
19 #if RTE_BYTE_ORDER == RTE_LITTLE_ENDIAN
69 uint64_t addr
; /* Byte addr of start-of-pkt */
133 uint64_t err_lev
: 3;
134 uint64_t op_code
: 8;
138 uint64_t addr
; /* Byte addr of start-of-pkt */
154 } __rte_packed octtx_wqe_t
;
156 enum occtx_pki_ltype_e
{
157 OCCTX_PKI_LTYPE_NONE
= 0,
158 OCCTX_PKI_LTYPE_ENET
= 1,
159 OCCTX_PKI_LTYPE_VLAN
= 2,
160 OCCTX_PKI_LTYPE_SNAP_PAYLD
= 5,
161 OCCTX_PKI_LTYPE_ARP
= 6,
162 OCCTX_PKI_LTYPE_RARP
= 7,
163 OCCTX_PKI_LTYPE_IP4
= 8,
164 OCCTX_PKI_LTYPE_IP4_OPT
= 9,
165 OCCTX_PKI_LTYPE_IP6
= 0xa,
166 OCCTX_PKI_LTYPE_IP6_OPT
= 0xb,
167 OCCTX_PKI_LTYPE_IPSEC_ESP
= 0xc,
168 OCCTX_PKI_LTYPE_IPFRAG
= 0xd,
169 OCCTX_PKI_LTYPE_IPCOMP
= 0xe,
170 OCCTX_PKI_LTYPE_TCP
= 0x10,
171 OCCTX_PKI_LTYPE_UDP
= 0x11,
172 OCCTX_PKI_LTYPE_SCTP
= 0x12,
173 OCCTX_PKI_LTYPE_UDP_VXLAN
= 0x13,
174 OCCTX_PKI_LTYPE_GRE
= 0x14,
175 OCCTX_PKI_LTYPE_NVGRE
= 0x15,
176 OCCTX_PKI_LTYPE_GTP
= 0x16,
177 OCCTX_PKI_LTYPE_UDP_GENEVE
= 0x17,
178 OCCTX_PKI_LTYPE_SW28
= 0x1c,
179 OCCTX_PKI_LTYPE_SW29
= 0x1d,
180 OCCTX_PKI_LTYPE_SW30
= 0x1e,
181 OCCTX_PKI_LTYPE_SW31
= 0x1f,
186 LC_NONE
= OCCTX_PKI_LTYPE_NONE
,
187 LC_IPV4
= OCCTX_PKI_LTYPE_IP4
,
188 LC_IPV4_OPT
= OCCTX_PKI_LTYPE_IP4_OPT
,
189 LC_IPV6
= OCCTX_PKI_LTYPE_IP6
,
190 LC_IPV6_OPT
= OCCTX_PKI_LTYPE_IP6_OPT
,
194 LE_NONE
= OCCTX_PKI_LTYPE_NONE
,
198 LF_NONE
= OCCTX_PKI_LTYPE_NONE
,
199 LF_IPSEC_ESP
= OCCTX_PKI_LTYPE_IPSEC_ESP
,
200 LF_IPFRAG
= OCCTX_PKI_LTYPE_IPFRAG
,
201 LF_IPCOMP
= OCCTX_PKI_LTYPE_IPCOMP
,
202 LF_TCP
= OCCTX_PKI_LTYPE_TCP
,
203 LF_UDP
= OCCTX_PKI_LTYPE_UDP
,
204 LF_GRE
= OCCTX_PKI_LTYPE_GRE
,
205 LF_UDP_GENEVE
= OCCTX_PKI_LTYPE_UDP_GENEVE
,
206 LF_UDP_VXLAN
= OCCTX_PKI_LTYPE_UDP_VXLAN
,
207 LF_NVGRE
= OCCTX_PKI_LTYPE_NVGRE
,
209 #endif /* __OCTEONTX_PKI_VAR_H__ */