[LEDE-DEV] [PATCH] linux/arc*: disable MAC frame filter in DW GMAC
Alexey Brodkin
Alexey.Brodkin at synopsys.com
Wed Jul 27 05:11:23 PDT 2016
For some [still unknown] reason in ARC SDP boards
DW GMAC doesn't enter promiscuous mode if eth0 gets
added to the br-lan interface before Ethernet PHY finishes
autonegotiation (PHY gets reset on DW GMAC start).
As a work-around we completely disable frame filtering
in GMAC hardware which gives us working bridge that consists
of eth0 and wlan0 (USB Wi-Fi dongle). I.e. we finally have
working "Dumb AP" setup made of ARC AXS10x boards.
Given this is pretty ugly hack we're applying it only for
affected platforms which do require eth0 to enter promiscuous
mode to operate in a bridge with wlan0.
Signed-off-by: Alexey Brodkin <abrodkin at synopsys.com>
---
...-stmmac-Disable-fame-filtering-completely.patch | 36 ++++++++++++++++++++++
...-stmmac-Disable-fame-filtering-completely.patch | 36 ++++++++++++++++++++++
2 files changed, 72 insertions(+)
create mode 100644 target/linux/arc770/patches-4.4/700-stmmac-Disable-fame-filtering-completely.patch
create mode 100644 target/linux/archs38/patches-4.4/700-stmmac-Disable-fame-filtering-completely.patch
diff --git a/target/linux/arc770/patches-4.4/700-stmmac-Disable-fame-filtering-completely.patch b/target/linux/arc770/patches-4.4/700-stmmac-Disable-fame-filtering-completely.patch
new file mode 100644
index 0000000..d47f155
--- /dev/null
+++ b/target/linux/arc770/patches-4.4/700-stmmac-Disable-fame-filtering-completely.patch
@@ -0,0 +1,36 @@
+From 0031b9011cb2b2b1de4dbb4f9620303aec760db4 Mon Sep 17 00:00:00 2001
+From: Alexey Brodkin <abrodkin at synopsys.com>
+Date: Wed, 27 Jul 2016 11:33:14 +0300
+Subject: [PATCH] stmmac: Disable fame filtering completely
+
+For some [still unknown] reason in ARC SDP boards
+DW GMAC doesn't enter promiscuous mode if eth0 gets
+added to the br-lan interface before Ethernet PHY finishes
+autonegotiation (PHY gets reset on DW GMAC start).
+
+As a work-around we completely disable frame filtering
+in GMAC hardware which gives us working bridge that consists
+of eth0 and wlan0 (USB Wi-Fi dongle). I.e. we finally have
+working "Dumb AP" setup made of ARC AXS10x boards.
+
+Signed-off-by: Alexey Brodkin <abrodkin at synopsys.com>
+---
+ drivers/net/ethernet/stmicro/stmmac/common.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/drivers/net/ethernet/stmicro/stmmac/common.h b/drivers/net/ethernet/stmicro/stmmac/common.h
+index 623c6ed..6396b81 100644
+--- a/drivers/net/ethernet/stmicro/stmmac/common.h
++++ b/drivers/net/ethernet/stmicro/stmmac/common.h
+@@ -42,7 +42,7 @@
+ #define DWMAC_CORE_3_50 0x35
+
+ #undef FRAME_FILTER_DEBUG
+-/* #define FRAME_FILTER_DEBUG */
++#define FRAME_FILTER_DEBUG
+
+ /* Extra statistic and debug information exposed by ethtool */
+ struct stmmac_extra_stats {
+--
+2.7.4
+
diff --git a/target/linux/archs38/patches-4.4/700-stmmac-Disable-fame-filtering-completely.patch b/target/linux/archs38/patches-4.4/700-stmmac-Disable-fame-filtering-completely.patch
new file mode 100644
index 0000000..d47f155
--- /dev/null
+++ b/target/linux/archs38/patches-4.4/700-stmmac-Disable-fame-filtering-completely.patch
@@ -0,0 +1,36 @@
+From 0031b9011cb2b2b1de4dbb4f9620303aec760db4 Mon Sep 17 00:00:00 2001
+From: Alexey Brodkin <abrodkin at synopsys.com>
+Date: Wed, 27 Jul 2016 11:33:14 +0300
+Subject: [PATCH] stmmac: Disable fame filtering completely
+
+For some [still unknown] reason in ARC SDP boards
+DW GMAC doesn't enter promiscuous mode if eth0 gets
+added to the br-lan interface before Ethernet PHY finishes
+autonegotiation (PHY gets reset on DW GMAC start).
+
+As a work-around we completely disable frame filtering
+in GMAC hardware which gives us working bridge that consists
+of eth0 and wlan0 (USB Wi-Fi dongle). I.e. we finally have
+working "Dumb AP" setup made of ARC AXS10x boards.
+
+Signed-off-by: Alexey Brodkin <abrodkin at synopsys.com>
+---
+ drivers/net/ethernet/stmicro/stmmac/common.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/drivers/net/ethernet/stmicro/stmmac/common.h b/drivers/net/ethernet/stmicro/stmmac/common.h
+index 623c6ed..6396b81 100644
+--- a/drivers/net/ethernet/stmicro/stmmac/common.h
++++ b/drivers/net/ethernet/stmicro/stmmac/common.h
+@@ -42,7 +42,7 @@
+ #define DWMAC_CORE_3_50 0x35
+
+ #undef FRAME_FILTER_DEBUG
+-/* #define FRAME_FILTER_DEBUG */
++#define FRAME_FILTER_DEBUG
+
+ /* Extra statistic and debug information exposed by ethtool */
+ struct stmmac_extra_stats {
+--
+2.7.4
+
--
2.7.4
More information about the Lede-dev
mailing list