diff options
Diffstat (limited to 'drivers/net/ethernet/intel/ice/ice_switch.c')
-rw-r--r-- | drivers/net/ethernet/intel/ice/ice_switch.c | 29 |
1 files changed, 20 insertions, 9 deletions
diff --git a/drivers/net/ethernet/intel/ice/ice_switch.c b/drivers/net/ethernet/intel/ice/ice_switch.c index 64e9e0cb61ce..48864b59036a 100644 --- a/drivers/net/ethernet/intel/ice/ice_switch.c +++ b/drivers/net/ethernet/intel/ice/ice_switch.c | |||
@@ -644,20 +644,31 @@ static void ice_fill_sw_info(struct ice_hw *hw, struct ice_fltr_info *fi) | |||
644 | fi->fltr_act == ICE_FWD_TO_Q || | 644 | fi->fltr_act == ICE_FWD_TO_Q || |
645 | fi->fltr_act == ICE_FWD_TO_QGRP)) { | 645 | fi->fltr_act == ICE_FWD_TO_QGRP)) { |
646 | fi->lb_en = true; | 646 | fi->lb_en = true; |
647 | /* Do not set lan_en to TRUE if | 647 | /* Set lan_en to TRUE if |
648 | * 1. The switch is a VEB AND | 648 | * 1. The switch is a VEB AND |
649 | * 2 | 649 | * 2 |
650 | * 2.1 The lookup is MAC with unicast addr for MAC, OR | 650 | * 2.1 The lookup is VLAN, OR |
651 | * 2.2 The lookup is MAC_VLAN with unicast addr for MAC | 651 | * 2.2 The lookup is default port mode, OR |
652 | * 2.3 The lookup is MAC with mcast or bcast addr for MAC, OR | ||
653 | * 2.4 The lookup is MAC_VLAN with mcast or bcast addr for MAC. | ||
652 | * | 654 | * |
653 | * In all other cases, the LAN enable has to be set to true. | 655 | * OR |
656 | * | ||
657 | * The switch is a VEPA. | ||
658 | * | ||
659 | * In all other cases, the LAN enable has to be set to false. | ||
654 | */ | 660 | */ |
655 | if (!(hw->evb_veb && | 661 | if (hw->evb_veb) { |
656 | ((fi->lkup_type == ICE_SW_LKUP_MAC && | 662 | if (fi->lkup_type == ICE_SW_LKUP_VLAN || |
657 | is_unicast_ether_addr(fi->l_data.mac.mac_addr)) || | 663 | fi->lkup_type == ICE_SW_LKUP_DFLT || |
658 | (fi->lkup_type == ICE_SW_LKUP_MAC_VLAN && | 664 | (fi->lkup_type == ICE_SW_LKUP_MAC && |
659 | is_unicast_ether_addr(fi->l_data.mac_vlan.mac_addr))))) | 665 | !is_unicast_ether_addr(fi->l_data.mac.mac_addr)) || |
666 | (fi->lkup_type == ICE_SW_LKUP_MAC_VLAN && | ||
667 | !is_unicast_ether_addr(fi->l_data.mac.mac_addr))) | ||
668 | fi->lan_en = true; | ||
669 | } else { | ||
660 | fi->lan_en = true; | 670 | fi->lan_en = true; |
671 | } | ||
661 | } | 672 | } |
662 | } | 673 | } |
663 | 674 | ||