Merge branch 'net-fix-using-wrong-flags-to-check-features'
Guangbin Huang says: ==================== net: fix using wrong flags to check features We find that some drivers may use wrong flags to check features, so fix them. ==================== Link: https://lore.kernel.org/r/20220729101755.4798-1-huangguangbin2@huawei.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
@@ -433,7 +433,7 @@ static int ice_vsi_sync_fltr(struct ice_vsi *vsi)
|
||||
IFF_PROMISC;
|
||||
goto out_promisc;
|
||||
}
|
||||
if (vsi->current_netdev_flags &
|
||||
if (vsi->netdev->features &
|
||||
NETIF_F_HW_VLAN_CTAG_FILTER)
|
||||
vlan_ops->ena_rx_filtering(vsi);
|
||||
}
|
||||
|
||||
@@ -1437,7 +1437,7 @@ static int ionic_set_nic_features(struct ionic_lif *lif,
|
||||
if ((old_hw_features ^ lif->hw_features) & IONIC_ETH_HW_RX_HASH)
|
||||
ionic_lif_rss_config(lif, lif->rss_types, NULL, NULL);
|
||||
|
||||
if ((vlan_flags & features) &&
|
||||
if ((vlan_flags & le64_to_cpu(ctx.cmd.lif_setattr.features)) &&
|
||||
!(vlan_flags & le64_to_cpu(ctx.comp.lif_setattr.features)))
|
||||
dev_info_once(lif->ionic->dev, "NIC is not supporting vlan offload, likely in SmartNIC mode\n");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user