diff options
author | Tony Nguyen <anthony.l.nguyen@intel.com> | 2020-01-17 07:39:13 -0800 |
---|---|---|
committer | Jeff Kirsher <jeffrey.t.kirsher@intel.com> | 2020-01-24 16:06:32 -0800 |
commit | 31ad4e4ee1e4e2e12985e46aa6263c8bd5ad4271 (patch) | |
tree | cbf13814243992bfaf27f9dddb360df2aa31c399 /drivers/net/ethernet/intel/ice/ice_flow.h | |
parent | c90ed40cefe187a20fc565650b119aa696abc2ed (diff) |
ice: Allocate flow profile
Create an extraction sequence based on the packet header protocols to be
programmed and allocate a flow profile for the extraction sequence.
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Signed-off-by: Henry Tieman <henry.w.tieman@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'drivers/net/ethernet/intel/ice/ice_flow.h')
-rw-r--r-- | drivers/net/ethernet/intel/ice/ice_flow.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/drivers/net/ethernet/intel/ice/ice_flow.h b/drivers/net/ethernet/intel/ice/ice_flow.h index 48c0fc09d5ff..05b0dab4793c 100644 --- a/drivers/net/ethernet/intel/ice/ice_flow.h +++ b/drivers/net/ethernet/intel/ice/ice_flow.h @@ -56,7 +56,13 @@ enum ice_flow_field { ICE_FLOW_FIELD_IDX_MAX }; +enum ice_flow_dir { + ICE_FLOW_RX = 0x02, +}; + #define ICE_FLOW_SEG_MAX 2 +#define ICE_FLOW_FV_EXTRACT_SZ 2 + #define ICE_FLOW_SET_HDRS(seg, val) ((seg)->hdrs |= (u32)(val)) struct ice_flow_seg_xtrct { @@ -99,6 +105,23 @@ struct ice_flow_seg_info { struct ice_flow_fld_info fields[ICE_FLOW_FIELD_IDX_MAX]; }; +struct ice_flow_prof { + struct list_head l_entry; + + u64 id; + enum ice_flow_dir dir; + u8 segs_cnt; + + /* Keep track of flow entries associated with this flow profile */ + struct mutex entries_lock; + struct list_head entries; + + struct ice_flow_seg_info segs[ICE_FLOW_SEG_MAX]; + + /* software VSI handles referenced by this flow profile */ + DECLARE_BITMAP(vsis, ICE_MAX_VSI); +}; + struct ice_rss_cfg { struct list_head l_entry; /* bitmap of VSIs added to the RSS entry */ |