Skip to content

Commit 210df56

Browse files
decsnyaescolar
authored andcommitted
drivers: ethernet: Add ETH_DSA_SUPPORT
Make DSA dependent on ETH_DSA_SUPPORT which is selected by driver kconfigs, rather than having a list of dependencies. Signed-off-by: Declan Snyder <[email protected]>
1 parent 2c4e755 commit 210df56

File tree

4 files changed

+10
-1
lines changed

4 files changed

+10
-1
lines changed

drivers/ethernet/Kconfig.dsa

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,14 @@
44
# Lukasz Majewski <[email protected]>
55
# SPDX-License-Identifier: Apache-2.0
66

7+
config ETH_DSA_SUPPORT
8+
bool
9+
help
10+
Set by an ethernet driver that supports DSA.
11+
712
menuconfig NET_DSA
813
bool "Distributed Switch Architecture support"
9-
depends on ETH_MCUX || ETH_SAM_GMAC || ETH_STM32_HAL || ETH_NXP_ENET
14+
depends on ETH_DSA_SUPPORT
1015
help
1116
Enable Distributed Switch Architecture support. For now it
1217
only supports Kinetics and STM32 ENET drivers.

drivers/ethernet/Kconfig.sam_gmac

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ menuconfig ETH_SAM_GMAC
1111
DT_HAS_ATMEL_SAM0_GMAC_ENABLED
1212
select NOCACHE_MEMORY if ARCH_HAS_NOCACHE_MEMORY_SUPPORT
1313
select MDIO
14+
select ETH_DSA_SUPPORT
1415
help
1516
Enable Atmel SAM MCU Family Ethernet driver.
1617

drivers/ethernet/Kconfig.stm32_hal

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ menuconfig ETH_STM32_HAL
1111
select USE_STM32_HAL_ETH
1212
select NOCACHE_MEMORY if SOC_SERIES_STM32H7X && CPU_CORTEX_M7
1313
select HWINFO
14+
select ETH_DSA_SUPPORT
1415
imply CRC
1516
help
1617
Enable STM32 HAL based Ethernet driver. It is available for

drivers/ethernet/nxp_enet/Kconfig

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ config ETH_NXP_ENET
1818
select ARM_MPU if CPU_CORTEX_M7
1919
select MDIO if DT_HAS_NXP_ENET_MDIO_ENABLED
2020
select NET_POWER_MANAGEMENT if (PM_DEVICE && SOC_FAMILY_KINETIS)
21+
select ETH_DSA_SUPPORT
2122
help
2223
Enable NXP ENET Ethernet driver.
2324

@@ -26,6 +27,7 @@ config ETH_MCUX
2627
select NOCACHE_MEMORY if HAS_MCUX_CACHE && CPU_HAS_DCACHE
2728
select ARM_MPU if CPU_CORTEX_M7
2829
select NET_POWER_MANAGEMENT if PM_DEVICE
30+
select ETH_DSA_SUPPORT
2931
select DEPRECATED
3032
help
3133
Enable deprecated legacy MCUX Ethernet driver.

0 commit comments

Comments
 (0)