summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCorentin Labbe <clabbe@baylibre.com>2019-05-13 13:06:39 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-05-16 19:42:34 +0200
commitaf91d7d20058b1c5397a3a919a169b19862d5efe (patch)
tree6154b2f310ec70f8550a73778f96eeab520e5f4a
parent77df11dae689c236d8cd65d1409c09d49aa19eb2 (diff)
downloadlinux-stable-af91d7d20058b1c5397a3a919a169b19862d5efe.tar.gz
linux-stable-af91d7d20058b1c5397a3a919a169b19862d5efe.tar.bz2
linux-stable-af91d7d20058b1c5397a3a919a169b19862d5efe.zip
net: ethernet: stmmac: dwmac-sun8i: enable support of unicast filtering
[ Upstream commit d4c26eb6e721683a0f93e346ce55bc8dc3cbb175 ] When adding more MAC addresses to a dwmac-sun8i interface, the device goes directly in promiscuous mode. This is due to IFF_UNICAST_FLT missing flag. So since the hardware support unicast filtering, let's add IFF_UNICAST_FLT. Fixes: 9f93ac8d4085 ("net-next: stmmac: Add dwmac-sun8i") Signed-off-by: Corentin Labbe <clabbe@baylibre.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c
index 14866331eced..a62128a444a6 100644
--- a/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c
+++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c
@@ -858,6 +858,8 @@ static struct mac_device_info *sun8i_dwmac_setup(void *ppriv)
mac->mac = &sun8i_dwmac_ops;
mac->dma = &sun8i_dwmac_dma_ops;
+ priv->dev->priv_flags |= IFF_UNICAST_FLT;
+
/* The loopback bit seems to be re-set when link change
* Simply mask it each time
* Speed 10/100/1000 are set in BIT(2)/BIT(3)