aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/ethernet')
-rw-r--r--drivers/net/ethernet/stmicro/stmmac/Kconfig50
-rw-r--r--drivers/net/ethernet/stmicro/stmmac/Makefile8
-rw-r--r--drivers/net/ethernet/stmicro/stmmac/stmmac.h9
-rw-r--r--drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c10
4 files changed, 9 insertions, 68 deletions
diff --git a/drivers/net/ethernet/stmicro/stmmac/Kconfig b/drivers/net/ethernet/stmicro/stmmac/Kconfig
index b02d4a3ffa37..40f356d9f21b 100644
--- a/drivers/net/ethernet/stmicro/stmmac/Kconfig
+++ b/drivers/net/ethernet/stmicro/stmmac/Kconfig
@@ -18,56 +18,14 @@ config STMMAC_PLATFORM
18 depends on STMMAC_ETH 18 depends on STMMAC_ETH
19 default y 19 default y
20 ---help--- 20 ---help---
21 This selects the platform specific bus support for 21 This selects the platform specific bus support for the stmmac driver.
22 the stmmac device driver. This is the driver used 22 This is the driver used on several SoCs:
23 on many embedded STM platforms based on ARM and SuperH 23 STi, Allwinner, Amlogic Meson, Altera SOCFPGA.
24 processors. 24
25 If you have a controller with this interface, say Y or M here. 25 If you have a controller with this interface, say Y or M here.
26 26
27 If unsure, say N. 27 If unsure, say N.
28 28
29config DWMAC_MESON
30 bool "Amlogic Meson dwmac support"
31 depends on STMMAC_PLATFORM && ARCH_MESON
32 help
33 Support for Ethernet controller on Amlogic Meson SoCs.
34
35 This selects the Amlogic Meson SoC glue layer support for
36 the stmmac device driver. This driver is used for Meson6 and
37 Meson8 SoCs.
38
39config DWMAC_SOCFPGA
40 bool "SOCFPGA dwmac support"
41 depends on STMMAC_PLATFORM && MFD_SYSCON && (ARCH_SOCFPGA || COMPILE_TEST)
42 help
43 Support for ethernet controller on Altera SOCFPGA
44
45 This selects the Altera SOCFPGA SoC glue layer support
46 for the stmmac device driver. This driver is used for
47 arria5 and cyclone5 FPGA SoCs.
48
49config DWMAC_SUNXI
50 bool "Allwinner GMAC support"
51 depends on STMMAC_PLATFORM && ARCH_SUNXI
52 default y
53 ---help---
54 Support for Allwinner A20/A31 GMAC ethernet controllers.
55
56 This selects Allwinner SoC glue layer support for the
57 stmmac device driver. This driver is used for A20/A31
58 GMAC ethernet controller.
59
60config DWMAC_STI
61 bool "STi GMAC support"
62 depends on STMMAC_PLATFORM && ARCH_STI
63 default y
64 ---help---
65 Support for ethernet controller on STi SOCs.
66
67 This selects STi SoC glue layer support for the stmmac
68 device driver. This driver is used on for the STi series
69 SOCs GMAC ethernet controller.
70
71config STMMAC_PCI 29config STMMAC_PCI
72 bool "STMMAC PCI bus support" 30 bool "STMMAC PCI bus support"
73 depends on STMMAC_ETH && PCI 31 depends on STMMAC_ETH && PCI
diff --git a/drivers/net/ethernet/stmicro/stmmac/Makefile b/drivers/net/ethernet/stmicro/stmmac/Makefile
index 0533d0ba783d..034da704f22f 100644
--- a/drivers/net/ethernet/stmicro/stmmac/Makefile
+++ b/drivers/net/ethernet/stmicro/stmmac/Makefile
@@ -1,10 +1,8 @@
1obj-$(CONFIG_STMMAC_ETH) += stmmac.o 1obj-$(CONFIG_STMMAC_ETH) += stmmac.o
2stmmac-$(CONFIG_STMMAC_PLATFORM) += stmmac_platform.o
3stmmac-$(CONFIG_STMMAC_PCI) += stmmac_pci.o 2stmmac-$(CONFIG_STMMAC_PCI) += stmmac_pci.o
4stmmac-$(CONFIG_DWMAC_MESON) += dwmac-meson.o 3stmmac-$(CONFIG_STMMAC_PLATFORM) += stmmac_platform.o dwmac-meson.o \
5stmmac-$(CONFIG_DWMAC_SUNXI) += dwmac-sunxi.o 4 dwmac-sunxi.o dwmac-sti.o \
6stmmac-$(CONFIG_DWMAC_STI) += dwmac-sti.o 5 dwmac-socfpga.o
7stmmac-$(CONFIG_DWMAC_SOCFPGA) += dwmac-socfpga.o
8stmmac-objs:= stmmac_main.o stmmac_ethtool.o stmmac_mdio.o ring_mode.o \ 6stmmac-objs:= stmmac_main.o stmmac_ethtool.o stmmac_mdio.o ring_mode.o \
9 chain_mode.o dwmac_lib.o dwmac1000_core.o dwmac1000_dma.o \ 7 chain_mode.o dwmac_lib.o dwmac1000_core.o dwmac1000_dma.o \
10 dwmac100_core.o dwmac100_dma.o enh_desc.o norm_desc.o \ 8 dwmac100_core.o dwmac100_dma.o enh_desc.o norm_desc.o \
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac.h b/drivers/net/ethernet/stmicro/stmmac/stmmac.h
index c3c40650b309..23aad9adef5a 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac.h
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac.h
@@ -137,20 +137,13 @@ void stmmac_disable_eee_mode(struct stmmac_priv *priv);
137bool stmmac_eee_init(struct stmmac_priv *priv); 137bool stmmac_eee_init(struct stmmac_priv *priv);
138 138
139#ifdef CONFIG_STMMAC_PLATFORM 139#ifdef CONFIG_STMMAC_PLATFORM
140#ifdef CONFIG_DWMAC_MESON
141extern const struct stmmac_of_data meson6_dwmac_data; 140extern const struct stmmac_of_data meson6_dwmac_data;
142#endif
143#ifdef CONFIG_DWMAC_SUNXI
144extern const struct stmmac_of_data sun7i_gmac_data; 141extern const struct stmmac_of_data sun7i_gmac_data;
145#endif
146#ifdef CONFIG_DWMAC_STI
147extern const struct stmmac_of_data stih4xx_dwmac_data; 142extern const struct stmmac_of_data stih4xx_dwmac_data;
148extern const struct stmmac_of_data stid127_dwmac_data; 143extern const struct stmmac_of_data stid127_dwmac_data;
149#endif
150#ifdef CONFIG_DWMAC_SOCFPGA
151extern const struct stmmac_of_data socfpga_gmac_data; 144extern const struct stmmac_of_data socfpga_gmac_data;
152#endif
153extern struct platform_driver stmmac_pltfr_driver; 145extern struct platform_driver stmmac_pltfr_driver;
146
154static inline int stmmac_register_platform(void) 147static inline int stmmac_register_platform(void)
155{ 148{
156 int err; 149 int err;
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
index db56fa7ce8f9..f4fe854f3ee3 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
@@ -30,22 +30,14 @@
30#include "stmmac.h" 30#include "stmmac.h"
31 31
32static const struct of_device_id stmmac_dt_ids[] = { 32static const struct of_device_id stmmac_dt_ids[] = {
33#ifdef CONFIG_DWMAC_MESON 33 /* SoC specific glue layers should come before generic bindings */
34 { .compatible = "amlogic,meson6-dwmac", .data = &meson6_dwmac_data}, 34 { .compatible = "amlogic,meson6-dwmac", .data = &meson6_dwmac_data},
35#endif
36#ifdef CONFIG_DWMAC_SUNXI
37 { .compatible = "allwinner,sun7i-a20-gmac", .data = &sun7i_gmac_data}, 35 { .compatible = "allwinner,sun7i-a20-gmac", .data = &sun7i_gmac_data},
38#endif
39#ifdef CONFIG_DWMAC_STI
40 { .compatible = "st,stih415-dwmac", .data = &stih4xx_dwmac_data}, 36 { .compatible = "st,stih415-dwmac", .data = &stih4xx_dwmac_data},
41 { .compatible = "st,stih416-dwmac", .data = &stih4xx_dwmac_data}, 37 { .compatible = "st,stih416-dwmac", .data = &stih4xx_dwmac_data},
42 { .compatible = "st,stid127-dwmac", .data = &stid127_dwmac_data}, 38 { .compatible = "st,stid127-dwmac", .data = &stid127_dwmac_data},
43 { .compatible = "st,stih407-dwmac", .data = &stih4xx_dwmac_data}, 39 { .compatible = "st,stih407-dwmac", .data = &stih4xx_dwmac_data},
44#endif
45#ifdef CONFIG_DWMAC_SOCFPGA
46 { .compatible = "altr,socfpga-stmmac", .data = &socfpga_gmac_data }, 40 { .compatible = "altr,socfpga-stmmac", .data = &socfpga_gmac_data },
47#endif
48 /* SoC specific glue layers should come before generic bindings */
49 { .compatible = "st,spear600-gmac"}, 41 { .compatible = "st,spear600-gmac"},
50 { .compatible = "snps,dwmac-3.610"}, 42 { .compatible = "snps,dwmac-3.610"},
51 { .compatible = "snps,dwmac-3.70a"}, 43 { .compatible = "snps,dwmac-3.70a"},