Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJiri Slaby <jslaby@suse.cz>2019-05-17 06:38:43 +0200
committerJiri Slaby <jslaby@suse.cz>2019-05-17 06:38:49 +0200
commitd6916982b62d8361c4abd80596821c82612709b2 (patch)
tree76e41e1b5a97a57da8e5f4a726c7853f312f5c6a
parent847473abab08c0b87ab7487ae2a331c4520b9165 (diff)
net: ethernet: stmmac: dwmac-sun8i: enable support of unicast
filtering (bnc#1012628).
-rw-r--r--patches.kernel.org/5.1.3-020-net-ethernet-stmmac-dwmac-sun8i-enable-support-.patch41
-rw-r--r--series.conf1
2 files changed, 42 insertions, 0 deletions
diff --git a/patches.kernel.org/5.1.3-020-net-ethernet-stmmac-dwmac-sun8i-enable-support-.patch b/patches.kernel.org/5.1.3-020-net-ethernet-stmmac-dwmac-sun8i-enable-support-.patch
new file mode 100644
index 0000000000..2fd2f1e92d
--- /dev/null
+++ b/patches.kernel.org/5.1.3-020-net-ethernet-stmmac-dwmac-sun8i-enable-support-.patch
@@ -0,0 +1,41 @@
+From: Corentin Labbe <clabbe@baylibre.com>
+Date: Mon, 13 May 2019 13:06:39 +0000
+Subject: [PATCH] net: ethernet: stmmac: dwmac-sun8i: enable support of unicast
+ filtering
+References: bnc#1012628
+Patch-mainline: 5.1.3
+Git-commit: d4c26eb6e721683a0f93e346ce55bc8dc3cbb175
+
+[ 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>
+Signed-off-by: Jiri Slaby <jslaby@suse.cz>
+---
+ drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c
+index 195669f550f0..ba124a4da793 100644
+--- a/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c
++++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c
+@@ -1015,6 +1015,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)
+--
+2.21.0
+
diff --git a/series.conf b/series.conf
index b3f63e3ae6..75adc0cdbc 100644
--- a/series.conf
+++ b/series.conf
@@ -105,6 +105,7 @@
patches.kernel.org/5.1.3-017-fib_rules-return-0-directly-if-an-exactly-same-.patch
patches.kernel.org/5.1.3-018-ipv4-Fix-raw-socket-lookup-for-local-traffic.patch
patches.kernel.org/5.1.3-019-net-dsa-Fix-error-cleanup-path-in-dsa_init_modu.patch
+ patches.kernel.org/5.1.3-020-net-ethernet-stmmac-dwmac-sun8i-enable-support-.patch
########################################################
# Build fixes that apply to the vanilla kernel too.