Changeset View
Changeset View
Standalone View
Standalone View
sys/dev/ice/ice_flex_type.h
Show First 20 Lines • Show All 606 Lines • ▼ Show 20 Lines | |||||
/* VSIG bit layout: | /* VSIG bit layout: | ||||
* [0:12]: incremental VSIG index 1 to ICE_MAX_VSIGS | * [0:12]: incremental VSIG index 1 to ICE_MAX_VSIGS | ||||
* [13:15]: PF number of device | * [13:15]: PF number of device | ||||
*/ | */ | ||||
#define ICE_VSIG_IDX_M (0x1FFF) | #define ICE_VSIG_IDX_M (0x1FFF) | ||||
#define ICE_PF_NUM_S 13 | #define ICE_PF_NUM_S 13 | ||||
#define ICE_PF_NUM_M (0x07 << ICE_PF_NUM_S) | #define ICE_PF_NUM_M (0x07 << ICE_PF_NUM_S) | ||||
#define ICE_VSIG_VALUE(vsig, pf_id) \ | #define ICE_VSIG_VALUE(vsig, pf_id) \ | ||||
(u16)((((u16)(vsig)) & ICE_VSIG_IDX_M) | \ | ((u16)((((u16)(vsig)) & ICE_VSIG_IDX_M) | \ | ||||
(((u16)(pf_id) << ICE_PF_NUM_S) & ICE_PF_NUM_M)) | (((u16)(pf_id) << ICE_PF_NUM_S) & ICE_PF_NUM_M))) | ||||
#define ICE_DEFAULT_VSIG 0 | #define ICE_DEFAULT_VSIG 0 | ||||
/* XLT2 Table */ | /* XLT2 Table */ | ||||
struct ice_xlt2 { | struct ice_xlt2 { | ||||
struct ice_vsig_entry *vsig_tbl; | struct ice_vsig_entry *vsig_tbl; | ||||
struct ice_vsig_vsi *vsis; | struct ice_vsig_vsi *vsis; | ||||
u16 *t; | u16 *t; | ||||
u32 sid; | u32 sid; | ||||
▲ Show 20 Lines • Show All 99 Lines • ▼ Show 20 Lines | |||||
#define ICE_FLOW_PTYPE_MAX ICE_XLT1_CNT | #define ICE_FLOW_PTYPE_MAX ICE_XLT1_CNT | ||||
enum ice_prof_type { | enum ice_prof_type { | ||||
ICE_PROF_NON_TUN = 0x1, | ICE_PROF_NON_TUN = 0x1, | ||||
ICE_PROF_TUN_UDP = 0x2, | ICE_PROF_TUN_UDP = 0x2, | ||||
ICE_PROF_TUN_GRE = 0x4, | ICE_PROF_TUN_GRE = 0x4, | ||||
ICE_PROF_TUN_ALL = 0x6, | ICE_PROF_TUN_ALL = 0x6, | ||||
ICE_PROF_ALL = 0xFF, | ICE_PROF_ALL = 0xFF, | ||||
}; | |||||
/* Number of bits/bytes contained in meta init entry. Note, this should be a | |||||
* multiple of 32 bits. | |||||
*/ | |||||
#define ICE_META_INIT_BITS 192 | |||||
#define ICE_META_INIT_DW_CNT (ICE_META_INIT_BITS / (sizeof(__le32) * \ | |||||
BITS_PER_BYTE)) | |||||
/* The meta init Flag field starts at this bit */ | |||||
#define ICE_META_FLAGS_ST 123 | |||||
/* The entry and bit to check for Double VLAN Mode (DVM) support */ | |||||
#define ICE_META_VLAN_MODE_ENTRY 0 | |||||
#define ICE_META_FLAG_VLAN_MODE 60 | |||||
#define ICE_META_VLAN_MODE_BIT (ICE_META_FLAGS_ST + \ | |||||
ICE_META_FLAG_VLAN_MODE) | |||||
struct ice_meta_init_entry { | |||||
__le32 bm[ICE_META_INIT_DW_CNT]; | |||||
}; | |||||
struct ice_meta_init_section { | |||||
__le16 count; | |||||
__le16 offset; | |||||
struct ice_meta_init_entry entry[1]; | |||||
}; | }; | ||||
#endif /* _ICE_FLEX_TYPE_H_ */ | #endif /* _ICE_FLEX_TYPE_H_ */ |