162306a36Sopenharmony_ci# SPDX-License-Identifier: GPL-2.0-only
262306a36Sopenharmony_ciconfig STMMAC_ETH
362306a36Sopenharmony_ci	tristate "STMicroelectronics Multi-Gigabit Ethernet driver"
462306a36Sopenharmony_ci	depends on HAS_IOMEM && HAS_DMA
562306a36Sopenharmony_ci	depends on PTP_1588_CLOCK_OPTIONAL
662306a36Sopenharmony_ci	select MII
762306a36Sopenharmony_ci	select PCS_XPCS
862306a36Sopenharmony_ci	select PAGE_POOL
962306a36Sopenharmony_ci	select PHYLINK
1062306a36Sopenharmony_ci	select CRC32
1162306a36Sopenharmony_ci	select RESET_CONTROLLER
1262306a36Sopenharmony_ci	help
1362306a36Sopenharmony_ci	  This is the driver for the Ethernet IPs built around a
1462306a36Sopenharmony_ci	  Synopsys IP Core.
1562306a36Sopenharmony_ci
1662306a36Sopenharmony_ciif STMMAC_ETH
1762306a36Sopenharmony_ci
1862306a36Sopenharmony_ciconfig STMMAC_SELFTESTS
1962306a36Sopenharmony_ci	bool "Support for STMMAC Selftests"
2062306a36Sopenharmony_ci	depends on INET
2162306a36Sopenharmony_ci	depends on STMMAC_ETH
2262306a36Sopenharmony_ci	default n
2362306a36Sopenharmony_ci	help
2462306a36Sopenharmony_ci	  This adds support for STMMAC Selftests using ethtool. Enable this
2562306a36Sopenharmony_ci	  feature if you are facing problems with your HW and submit the test
2662306a36Sopenharmony_ci	  results to the netdev Mailing List.
2762306a36Sopenharmony_ci
2862306a36Sopenharmony_ciconfig STMMAC_PLATFORM
2962306a36Sopenharmony_ci	tristate "STMMAC Platform bus support"
3062306a36Sopenharmony_ci	depends on STMMAC_ETH
3162306a36Sopenharmony_ci	select MFD_SYSCON
3262306a36Sopenharmony_ci	default y
3362306a36Sopenharmony_ci	help
3462306a36Sopenharmony_ci	  This selects the platform specific bus support for the stmmac driver.
3562306a36Sopenharmony_ci	  This is the driver used on several SoCs:
3662306a36Sopenharmony_ci	  STi, Allwinner, Amlogic Meson, Altera SOCFPGA.
3762306a36Sopenharmony_ci
3862306a36Sopenharmony_ci	  If you have a controller with this interface, say Y or M here.
3962306a36Sopenharmony_ci
4062306a36Sopenharmony_ci	  If unsure, say N.
4162306a36Sopenharmony_ci
4262306a36Sopenharmony_ciif STMMAC_PLATFORM
4362306a36Sopenharmony_ci
4462306a36Sopenharmony_ciconfig DWMAC_DWC_QOS_ETH
4562306a36Sopenharmony_ci	tristate "Support for snps,dwc-qos-ethernet.txt DT binding."
4662306a36Sopenharmony_ci	select CRC32
4762306a36Sopenharmony_ci	select MII
4862306a36Sopenharmony_ci	depends on OF && HAS_DMA
4962306a36Sopenharmony_ci	help
5062306a36Sopenharmony_ci	  Support for chips using the snps,dwc-qos-ethernet.txt DT binding.
5162306a36Sopenharmony_ci
5262306a36Sopenharmony_ciconfig DWMAC_GENERIC
5362306a36Sopenharmony_ci	tristate "Generic driver for DWMAC"
5462306a36Sopenharmony_ci	default STMMAC_PLATFORM
5562306a36Sopenharmony_ci	help
5662306a36Sopenharmony_ci	  Generic DWMAC driver for platforms that don't require any
5762306a36Sopenharmony_ci	  platform specific code to function or is using platform
5862306a36Sopenharmony_ci	  data for setup.
5962306a36Sopenharmony_ci
6062306a36Sopenharmony_ciconfig DWMAC_ANARION
6162306a36Sopenharmony_ci	tristate "Adaptrum Anarion GMAC support"
6262306a36Sopenharmony_ci	default ARC
6362306a36Sopenharmony_ci	depends on OF && (ARC || COMPILE_TEST)
6462306a36Sopenharmony_ci	help
6562306a36Sopenharmony_ci	  Support for Adaptrum Anarion GMAC Ethernet controller.
6662306a36Sopenharmony_ci
6762306a36Sopenharmony_ci	  This selects the Anarion SoC glue layer support for the stmmac driver.
6862306a36Sopenharmony_ci
6962306a36Sopenharmony_ciconfig DWMAC_INGENIC
7062306a36Sopenharmony_ci	tristate "Ingenic MAC support"
7162306a36Sopenharmony_ci	default MACH_INGENIC
7262306a36Sopenharmony_ci	depends on OF && HAS_IOMEM && (MACH_INGENIC || COMPILE_TEST)
7362306a36Sopenharmony_ci	select MFD_SYSCON
7462306a36Sopenharmony_ci	help
7562306a36Sopenharmony_ci	  Support for ethernet controller on Ingenic SoCs.
7662306a36Sopenharmony_ci
7762306a36Sopenharmony_ci	  This selects Ingenic SoCs glue layer support for the stmmac
7862306a36Sopenharmony_ci	  device driver. This driver is used on for the Ingenic SoCs
7962306a36Sopenharmony_ci	  MAC ethernet controller.
8062306a36Sopenharmony_ci
8162306a36Sopenharmony_ciconfig DWMAC_IPQ806X
8262306a36Sopenharmony_ci	tristate "QCA IPQ806x DWMAC support"
8362306a36Sopenharmony_ci	default ARCH_QCOM
8462306a36Sopenharmony_ci	depends on OF && (ARCH_QCOM || COMPILE_TEST)
8562306a36Sopenharmony_ci	select MFD_SYSCON
8662306a36Sopenharmony_ci	help
8762306a36Sopenharmony_ci	  Support for QCA IPQ806X DWMAC Ethernet.
8862306a36Sopenharmony_ci
8962306a36Sopenharmony_ci	  This selects the IPQ806x SoC glue layer support for the stmmac
9062306a36Sopenharmony_ci	  device driver. This driver does not use any of the hardware
9162306a36Sopenharmony_ci	  acceleration features available on this SoC. Network devices
9262306a36Sopenharmony_ci	  will behave like standard non-accelerated ethernet interfaces.
9362306a36Sopenharmony_ci
9462306a36Sopenharmony_ci	  Select the QCOM_SOCINFO config flag to enable specific dwmac
9562306a36Sopenharmony_ci	  fixup based on the ipq806x SoC revision.
9662306a36Sopenharmony_ci
9762306a36Sopenharmony_ciconfig DWMAC_LPC18XX
9862306a36Sopenharmony_ci	tristate "NXP LPC18xx/43xx DWMAC support"
9962306a36Sopenharmony_ci	default ARCH_LPC18XX
10062306a36Sopenharmony_ci	depends on OF && (ARCH_LPC18XX || COMPILE_TEST)
10162306a36Sopenharmony_ci	select MFD_SYSCON
10262306a36Sopenharmony_ci	help
10362306a36Sopenharmony_ci	  Support for NXP LPC18xx/43xx DWMAC Ethernet.
10462306a36Sopenharmony_ci
10562306a36Sopenharmony_ciconfig DWMAC_MEDIATEK
10662306a36Sopenharmony_ci	tristate "MediaTek MT27xx GMAC support"
10762306a36Sopenharmony_ci	depends on OF && (ARCH_MEDIATEK || COMPILE_TEST)
10862306a36Sopenharmony_ci	help
10962306a36Sopenharmony_ci	  Support for MediaTek GMAC Ethernet controller.
11062306a36Sopenharmony_ci
11162306a36Sopenharmony_ci	  This selects the MT2712 SoC support for the stmmac driver.
11262306a36Sopenharmony_ci
11362306a36Sopenharmony_ciconfig DWMAC_MESON
11462306a36Sopenharmony_ci	tristate "Amlogic Meson dwmac support"
11562306a36Sopenharmony_ci	default ARCH_MESON
11662306a36Sopenharmony_ci	depends on OF && COMMON_CLK && (ARCH_MESON || COMPILE_TEST)
11762306a36Sopenharmony_ci	help
11862306a36Sopenharmony_ci	  Support for Ethernet controller on Amlogic Meson SoCs.
11962306a36Sopenharmony_ci
12062306a36Sopenharmony_ci	  This selects the Amlogic Meson SoC glue layer support for
12162306a36Sopenharmony_ci	  the stmmac device driver. This driver is used for Meson6,
12262306a36Sopenharmony_ci	  Meson8, Meson8b and GXBB SoCs.
12362306a36Sopenharmony_ci
12462306a36Sopenharmony_ciconfig DWMAC_QCOM_ETHQOS
12562306a36Sopenharmony_ci	tristate "Qualcomm ETHQOS support"
12662306a36Sopenharmony_ci	default ARCH_QCOM
12762306a36Sopenharmony_ci	depends on OF && (ARCH_QCOM || COMPILE_TEST)
12862306a36Sopenharmony_ci	help
12962306a36Sopenharmony_ci	  Support for the Qualcomm ETHQOS core.
13062306a36Sopenharmony_ci
13162306a36Sopenharmony_ci	  This selects the Qualcomm ETHQOS glue layer support for the
13262306a36Sopenharmony_ci	  stmmac device driver.
13362306a36Sopenharmony_ci
13462306a36Sopenharmony_ciconfig DWMAC_ROCKCHIP
13562306a36Sopenharmony_ci	tristate "Rockchip dwmac support"
13662306a36Sopenharmony_ci	default ARCH_ROCKCHIP
13762306a36Sopenharmony_ci	depends on OF && (ARCH_ROCKCHIP || COMPILE_TEST)
13862306a36Sopenharmony_ci	select MFD_SYSCON
13962306a36Sopenharmony_ci	help
14062306a36Sopenharmony_ci	  Support for Ethernet controller on Rockchip RK3288 SoC.
14162306a36Sopenharmony_ci
14262306a36Sopenharmony_ci	  This selects the Rockchip RK3288 SoC glue layer support for
14362306a36Sopenharmony_ci	  the stmmac device driver.
14462306a36Sopenharmony_ci
14562306a36Sopenharmony_ciconfig DWMAC_SOCFPGA
14662306a36Sopenharmony_ci	tristate "SOCFPGA dwmac support"
14762306a36Sopenharmony_ci	default ARCH_INTEL_SOCFPGA
14862306a36Sopenharmony_ci	depends on OF && (ARCH_INTEL_SOCFPGA || COMPILE_TEST)
14962306a36Sopenharmony_ci	select MFD_SYSCON
15062306a36Sopenharmony_ci	select MDIO_REGMAP
15162306a36Sopenharmony_ci	select REGMAP_MMIO
15262306a36Sopenharmony_ci	select PCS_LYNX
15362306a36Sopenharmony_ci	help
15462306a36Sopenharmony_ci	  Support for ethernet controller on Altera SOCFPGA
15562306a36Sopenharmony_ci
15662306a36Sopenharmony_ci	  This selects the Altera SOCFPGA SoC glue layer support
15762306a36Sopenharmony_ci	  for the stmmac device driver. This driver is used for
15862306a36Sopenharmony_ci	  arria5 and cyclone5 FPGA SoCs.
15962306a36Sopenharmony_ci
16062306a36Sopenharmony_ciconfig DWMAC_STARFIVE
16162306a36Sopenharmony_ci	tristate "StarFive dwmac support"
16262306a36Sopenharmony_ci	depends on OF && (ARCH_STARFIVE || COMPILE_TEST)
16362306a36Sopenharmony_ci	select MFD_SYSCON
16462306a36Sopenharmony_ci	default m if ARCH_STARFIVE
16562306a36Sopenharmony_ci	help
16662306a36Sopenharmony_ci	  Support for ethernet controllers on StarFive RISC-V SoCs
16762306a36Sopenharmony_ci
16862306a36Sopenharmony_ci	  This selects the StarFive platform specific glue layer support for
16962306a36Sopenharmony_ci	  the stmmac device driver. This driver is used for StarFive JH7110
17062306a36Sopenharmony_ci	  ethernet controller.
17162306a36Sopenharmony_ci
17262306a36Sopenharmony_ciconfig DWMAC_STI
17362306a36Sopenharmony_ci	tristate "STi GMAC support"
17462306a36Sopenharmony_ci	default ARCH_STI
17562306a36Sopenharmony_ci	depends on OF && (ARCH_STI || COMPILE_TEST)
17662306a36Sopenharmony_ci	select MFD_SYSCON
17762306a36Sopenharmony_ci	help
17862306a36Sopenharmony_ci	  Support for ethernet controller on STi SOCs.
17962306a36Sopenharmony_ci
18062306a36Sopenharmony_ci	  This selects STi SoC glue layer support for the stmmac
18162306a36Sopenharmony_ci	  device driver. This driver is used on for the STi series
18262306a36Sopenharmony_ci	  SOCs GMAC ethernet controller.
18362306a36Sopenharmony_ci
18462306a36Sopenharmony_ciconfig DWMAC_STM32
18562306a36Sopenharmony_ci	tristate "STM32 DWMAC support"
18662306a36Sopenharmony_ci	default ARCH_STM32
18762306a36Sopenharmony_ci	depends on OF && HAS_IOMEM && (ARCH_STM32 || COMPILE_TEST)
18862306a36Sopenharmony_ci	select MFD_SYSCON
18962306a36Sopenharmony_ci	help
19062306a36Sopenharmony_ci	  Support for ethernet controller on STM32 SOCs.
19162306a36Sopenharmony_ci
19262306a36Sopenharmony_ci	  This selects STM32 SoC glue layer support for the stmmac
19362306a36Sopenharmony_ci	  device driver. This driver is used on for the STM32 series
19462306a36Sopenharmony_ci	  SOCs GMAC ethernet controller.
19562306a36Sopenharmony_ci
19662306a36Sopenharmony_ciconfig DWMAC_SUNXI
19762306a36Sopenharmony_ci	tristate "Allwinner GMAC support"
19862306a36Sopenharmony_ci	default ARCH_SUNXI
19962306a36Sopenharmony_ci	depends on OF && (ARCH_SUNXI || COMPILE_TEST)
20062306a36Sopenharmony_ci	help
20162306a36Sopenharmony_ci	  Support for Allwinner A20/A31 GMAC ethernet controllers.
20262306a36Sopenharmony_ci
20362306a36Sopenharmony_ci	  This selects Allwinner SoC glue layer support for the
20462306a36Sopenharmony_ci	  stmmac device driver. This driver is used for A20/A31
20562306a36Sopenharmony_ci	  GMAC ethernet controller.
20662306a36Sopenharmony_ci
20762306a36Sopenharmony_ciconfig DWMAC_SUN8I
20862306a36Sopenharmony_ci	tristate "Allwinner sun8i GMAC support"
20962306a36Sopenharmony_ci	default ARCH_SUNXI
21062306a36Sopenharmony_ci	depends on OF && (ARCH_SUNXI || COMPILE_TEST)
21162306a36Sopenharmony_ci	select MDIO_BUS_MUX
21262306a36Sopenharmony_ci	help
21362306a36Sopenharmony_ci	  Support for Allwinner H3 A83T A64 EMAC ethernet controllers.
21462306a36Sopenharmony_ci
21562306a36Sopenharmony_ci	  This selects Allwinner SoC glue layer support for the
21662306a36Sopenharmony_ci	  stmmac device driver. This driver is used for H3/A83T/A64
21762306a36Sopenharmony_ci	  EMAC ethernet controller.
21862306a36Sopenharmony_ci
21962306a36Sopenharmony_ciconfig DWMAC_IMX8
22062306a36Sopenharmony_ci	tristate "NXP IMX8 DWMAC support"
22162306a36Sopenharmony_ci	default ARCH_MXC
22262306a36Sopenharmony_ci	depends on OF && (ARCH_MXC || COMPILE_TEST)
22362306a36Sopenharmony_ci	select MFD_SYSCON
22462306a36Sopenharmony_ci	help
22562306a36Sopenharmony_ci	  Support for ethernet controller on NXP i.MX8 SOCs.
22662306a36Sopenharmony_ci
22762306a36Sopenharmony_ci	  This selects NXP SoC glue layer support for the stmmac
22862306a36Sopenharmony_ci	  device driver. This driver is used for i.MX8 series like
22962306a36Sopenharmony_ci	  iMX8MP/iMX8DXL GMAC ethernet controller.
23062306a36Sopenharmony_ci
23162306a36Sopenharmony_ciconfig DWMAC_INTEL_PLAT
23262306a36Sopenharmony_ci	tristate "Intel dwmac support"
23362306a36Sopenharmony_ci	depends on OF && COMMON_CLK
23462306a36Sopenharmony_ci	depends on STMMAC_ETH
23562306a36Sopenharmony_ci	help
23662306a36Sopenharmony_ci	  Support for ethernet controllers on Intel SoCs
23762306a36Sopenharmony_ci
23862306a36Sopenharmony_ci	  This selects the Intel platform specific glue layer support for
23962306a36Sopenharmony_ci	  the stmmac device driver. This driver is used for the Intel Keem Bay
24062306a36Sopenharmony_ci	  SoC.
24162306a36Sopenharmony_ci
24262306a36Sopenharmony_ciconfig DWMAC_TEGRA
24362306a36Sopenharmony_ci	tristate "NVIDIA Tegra MGBE support"
24462306a36Sopenharmony_ci	depends on ARCH_TEGRA || COMPILE_TEST
24562306a36Sopenharmony_ci	help
24662306a36Sopenharmony_ci	  This selects the Multi-GigaBit Ethernet (MGBE) Controller that is
24762306a36Sopenharmony_ci	  found on the NVIDIA Tegra SoC devices. This driver provides the glue
24862306a36Sopenharmony_ci	  layer on top of the stmmac driver required for these NVIDIA Tegra SoC
24962306a36Sopenharmony_ci	  devices.
25062306a36Sopenharmony_ci
25162306a36Sopenharmony_ciconfig DWMAC_VISCONTI
25262306a36Sopenharmony_ci	tristate "Toshiba Visconti DWMAC support"
25362306a36Sopenharmony_ci	default ARCH_VISCONTI
25462306a36Sopenharmony_ci	depends on OF && COMMON_CLK && (ARCH_VISCONTI || COMPILE_TEST)
25562306a36Sopenharmony_ci	help
25662306a36Sopenharmony_ci	  Support for ethernet controller on Visconti SoCs.
25762306a36Sopenharmony_ci
25862306a36Sopenharmony_ciendif
25962306a36Sopenharmony_ci
26062306a36Sopenharmony_ciconfig DWMAC_INTEL
26162306a36Sopenharmony_ci	tristate "Intel GMAC support"
26262306a36Sopenharmony_ci	default X86
26362306a36Sopenharmony_ci	depends on X86 && STMMAC_ETH && PCI
26462306a36Sopenharmony_ci	depends on COMMON_CLK
26562306a36Sopenharmony_ci	help
26662306a36Sopenharmony_ci	  This selects the Intel platform specific bus support for the
26762306a36Sopenharmony_ci	  stmmac driver. This driver is used for Intel Quark/EHL/TGL.
26862306a36Sopenharmony_ci
26962306a36Sopenharmony_ciconfig DWMAC_LOONGSON
27062306a36Sopenharmony_ci	tristate "Loongson PCI DWMAC support"
27162306a36Sopenharmony_ci	default MACH_LOONGSON64
27262306a36Sopenharmony_ci	depends on (MACH_LOONGSON64 || COMPILE_TEST) && STMMAC_ETH && PCI
27362306a36Sopenharmony_ci	depends on COMMON_CLK
27462306a36Sopenharmony_ci	help
27562306a36Sopenharmony_ci	  This selects the LOONGSON PCI bus support for the stmmac driver,
27662306a36Sopenharmony_ci	  Support for ethernet controller on Loongson-2K1000 SoC and LS7A1000 bridge.
27762306a36Sopenharmony_ci
27862306a36Sopenharmony_ciconfig STMMAC_PCI
27962306a36Sopenharmony_ci	tristate "STMMAC PCI bus support"
28062306a36Sopenharmony_ci	depends on STMMAC_ETH && PCI
28162306a36Sopenharmony_ci	depends on COMMON_CLK
28262306a36Sopenharmony_ci	help
28362306a36Sopenharmony_ci	  This selects the platform specific bus support for the stmmac driver.
28462306a36Sopenharmony_ci	  This driver was tested on XLINX XC2V3000 FF1152AMT0221
28562306a36Sopenharmony_ci	  D1215994A VIRTEX FPGA board and SNPS QoS IPK Prototyping Kit.
28662306a36Sopenharmony_ci
28762306a36Sopenharmony_ci	  If you have a controller with this interface, say Y or M here.
28862306a36Sopenharmony_ci
28962306a36Sopenharmony_ci	  If unsure, say N.
29062306a36Sopenharmony_ciendif
291