Commit ac73e1be authored by Jose Abreu's avatar Jose Abreu Committed by Stefan Bader

net: stmmac: dwmac1000: Clear unused address entries

BugLink: https://bugs.launchpad.net/bugs/1840081

[ Upstream commit 9463c445 ]

In case we don't use a given address entry we need to clear it because
it could contain previous values that are no longer valid.

Found out while running stmmac selftests.
Signed-off-by: default avatarJose Abreu <joabreu@synopsys.com>
Cc: Joao Pinto <jpinto@synopsys.com>
Cc: David S. Miller <davem@davemloft.net>
Cc: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Cc: Alexandre Torgue <alexandre.torgue@st.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarConnor Kuehl <connor.kuehl@canonical.com>
Signed-off-by: default avatarKleber Sacilotto de Souza <kleber.souza@canonical.com>
parent 36df483a
...@@ -187,6 +187,12 @@ static void dwmac1000_set_filter(struct mac_device_info *hw, ...@@ -187,6 +187,12 @@ static void dwmac1000_set_filter(struct mac_device_info *hw,
GMAC_ADDR_LOW(reg)); GMAC_ADDR_LOW(reg));
reg++; reg++;
} }
while (reg <= perfect_addr_number) {
writel(0, ioaddr + GMAC_ADDR_HIGH(reg));
writel(0, ioaddr + GMAC_ADDR_LOW(reg));
reg++;
}
} }
#ifdef FRAME_FILTER_DEBUG #ifdef FRAME_FILTER_DEBUG
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment