aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/intel/ice/ice_switch.h
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2023-05-22 12:44:44 +0100
committerDavid S. Miller <davem@davemloft.net>2023-05-22 12:44:44 +0100
commitd49b9b07725f5dfa3344dc3eed59b8ccc0a0ddbc (patch)
tree001c24bd24b6dc0775b14f5236a7b5932c8695be /drivers/net/ethernet/intel/ice/ice_switch.h
parentefc3001f8b44bf5da0f178bd726a73c73f370707 (diff)
parent0ef4479d13af4c5516920520d9cf7bcfe801b353 (diff)
downloadlinux-d49b9b07725f5dfa3344dc3eed59b8ccc0a0ddbc.tar.gz
linux-d49b9b07725f5dfa3344dc3eed59b8ccc0a0ddbc.tar.bz2
linux-d49b9b07725f5dfa3344dc3eed59b8ccc0a0ddbc.zip
Merge branch '100GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue
Tony Nguyen says: ==================== ice: allow matching on meta data Michal Swiatkowski says: This patchset is intended to improve the usability of the switchdev slow path. Without matching on a meta data values slow path works based on VF's MAC addresses. It causes a problem when the VF wants to use more than one MAC address (e.g. when it is in trusted mode). Parse all meta data in the same place where protocol type fields are parsed. Add description for the currently implemented meta data. It is important to note that depending on DDP not all described meta data can be available. Using not available meta data leads to error returned by function which is looking for correct words in profiles read from DDP. There is also one small improvement, remove of rx field in rule info structure (patch 2). It is redundant. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/intel/ice/ice_switch.h')
-rw-r--r--drivers/net/ethernet/intel/ice/ice_switch.h13
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/net/ethernet/intel/ice/ice_switch.h b/drivers/net/ethernet/intel/ice/ice_switch.h
index 68d8e8a6a189..c84b56fe84a5 100644
--- a/drivers/net/ethernet/intel/ice/ice_switch.h
+++ b/drivers/net/ethernet/intel/ice/ice_switch.h
@@ -10,7 +10,6 @@
#define ICE_DFLT_VSI_INVAL 0xff
#define ICE_FLTR_RX BIT(0)
#define ICE_FLTR_TX BIT(1)
-#define ICE_FLTR_TX_RX (ICE_FLTR_RX | ICE_FLTR_TX)
#define ICE_VSI_INVAL_ID 0xffff
#define ICE_INVAL_Q_HANDLE 0xFFFF
@@ -187,12 +186,13 @@ struct ice_adv_rule_flags_info {
};
struct ice_adv_rule_info {
+ /* Store metadata values in rule info */
enum ice_sw_tunnel_type tun_type;
- struct ice_sw_act_ctrl sw_act;
- u32 priority;
- u8 rx; /* true means LOOKUP_RX otherwise LOOKUP_TX */
- u16 fltr_rule_id;
u16 vlan_type;
+ u16 fltr_rule_id;
+ u32 priority;
+ u16 src_vsi;
+ struct ice_sw_act_ctrl sw_act;
struct ice_adv_rule_flags_info flags_info;
};
@@ -342,6 +342,9 @@ ice_free_res_cntr(struct ice_hw *hw, u8 type, u8 alloc_shared, u16 num_items,
u16 counter_id);
/* Switch/bridge related commands */
+void ice_rule_add_tunnel_metadata(struct ice_adv_lkup_elem *lkup);
+void ice_rule_add_vlan_metadata(struct ice_adv_lkup_elem *lkup);
+void ice_rule_add_src_vsi_metadata(struct ice_adv_lkup_elem *lkup);
int
ice_add_adv_rule(struct ice_hw *hw, struct ice_adv_lkup_elem *lkups,
u16 lkups_cnt, struct ice_adv_rule_info *rinfo,