You've already forked linux-rockchip
mirror of
https://github.com/armbian/linux-rockchip.git
synced 2026-01-06 11:08:10 -08:00
ethernet: dwmac4: fix VLAN in promisc mode not supported
This commit is contained in:
committed by
Jianfeng Liu
parent
0211a4fd8f
commit
2883d11e25
@@ -453,12 +453,6 @@ static int dwmac4_add_hw_vlan_rx_fltr(struct net_device *dev,
|
||||
if (vid > 4095)
|
||||
return -EINVAL;
|
||||
|
||||
if (hw->promisc) {
|
||||
netdev_err(dev,
|
||||
"Adding VLAN in promisc mode not supported\n");
|
||||
return -EPERM;
|
||||
}
|
||||
|
||||
/* Single Rx VLAN Filter */
|
||||
if (hw->num_vlan == 1) {
|
||||
/* For single VLAN filter, VID 0 means VLAN promiscuous */
|
||||
@@ -508,12 +502,6 @@ static int dwmac4_del_hw_vlan_rx_fltr(struct net_device *dev,
|
||||
{
|
||||
int i, ret = 0;
|
||||
|
||||
if (hw->promisc) {
|
||||
netdev_err(dev,
|
||||
"Deleting VLAN in promisc mode not supported\n");
|
||||
return -EPERM;
|
||||
}
|
||||
|
||||
/* Single Rx VLAN Filter */
|
||||
if (hw->num_vlan == 1) {
|
||||
if ((hw->vlan_filter[0] & GMAC_VLAN_TAG_VID) == vid) {
|
||||
|
||||
Reference in New Issue
Block a user