diff options
author | Jian Shen <shenjian15@huawei.com> | 2018-10-12 17:34:04 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-10-12 21:23:45 +0300 |
commit | c60edc17df391e33c9c3cd6e319eb1f32ce26730 (patch) | |
tree | 07d434f5945d26a1ff40dfd27d6fb3e27e5b811d /drivers/net/ethernet/hisilicon/hns3/hns3_enet.h | |
parent | 5886d932e52acfbe12ea5aac8e7c3ad6f16364d1 (diff) | |
download | linux-c60edc17df391e33c9c3cd6e319eb1f32ce26730.tar.xz |
net: hns3: Enable promisc mode when mac vlan table is full
Currently, the driver does nothing when mac vlan table is full.
In this case, the packet with new mac address will be dropped
by hardware. This patch adds check for the result of sync mac
address, and enable promisc mode when mac vlan table is full.
Furtherly, disable vlan filter when enable promisc by user
command.
Fixes: 46a3df9f9718 ("net: hns3: Add HNS3 Acceleration Engine & Compatibility Layer Support")
Signed-off-by: Jian Shen <shenjian15@huawei.com>
Signed-off-by: Salil Mehta <salil.mehta@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/hisilicon/hns3/hns3_enet.h')
-rw-r--r-- | drivers/net/ethernet/hisilicon/hns3/hns3_enet.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3_enet.h b/drivers/net/ethernet/hisilicon/hns3/hns3_enet.h index ac881e8fc05d..f25b281ff2aa 100644 --- a/drivers/net/ethernet/hisilicon/hns3/hns3_enet.h +++ b/drivers/net/ethernet/hisilicon/hns3/hns3_enet.h @@ -640,6 +640,9 @@ void hns3_set_vector_coalesce_tx_gl(struct hns3_enet_tqp_vector *tqp_vector, void hns3_set_vector_coalesce_rl(struct hns3_enet_tqp_vector *tqp_vector, u32 rl_value); +void hns3_enable_vlan_filter(struct net_device *netdev, bool enable); +void hns3_update_promisc_mode(struct net_device *netdev, u8 promisc_flags); + #ifdef CONFIG_HNS3_DCB void hns3_dcbnl_setup(struct hnae3_handle *handle); #else |