net: stmmac: xgmac: Reinitialize correctly a variable
authorJose Abreu <Jose.Abreu@synopsys.com>
Tue, 10 Sep 2019 14:41:24 +0000 (16:41 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 11 Sep 2019 08:21:34 +0000 (09:21 +0100)
'value' was being or'ed with a value from another register. This is a
typo and could cause new written value to be wrong. Fix it.

Signed-off-by: Jose Abreu <joabreu@synopsys.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/stmicro/stmmac/dwxgmac2_core.c

index 78ac659da2792d1855c70b69b500dc77418841b4..d5173dd02a711ed7bfb9a74a91ebc0963716cf0e 100644 (file)
@@ -568,7 +568,7 @@ static void dwxgmac2_update_vlan_hash(struct mac_device_info *hw, u32 hash,
 
                writel(value, ioaddr + XGMAC_PACKET_FILTER);
 
-               value |= XGMAC_VLAN_VTHM | XGMAC_VLAN_ETV;
+               value = XGMAC_VLAN_VTHM | XGMAC_VLAN_ETV;
                if (is_double) {
                        value |= XGMAC_VLAN_EDVLP;
                        value |= XGMAC_VLAN_ESVL;