ethernet: smsc91x: select MDIO

This driver implements an MDIO device. Enable the MDIO driver to avoid a
build error for:

orphan section `._device.static.3_CONFIG_MDIO_INIT_PRIORITY_'

Also set the proper compatible in mdio_shell so that the ethernet tests
build correctly.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
This commit is contained in:
Fabio Baltieri 2023-07-31 09:50:22 +00:00 committed by Carles Cufí
parent 530d16915a
commit acbb7a39bb
2 changed files with 3 additions and 0 deletions

View file

@ -5,5 +5,6 @@ config ETH_SMSC91X
bool "SMSC91x Ethernet driver"
default y
depends on DT_HAS_SMSC_LAN91C111_ENABLED
select MDIO
help
Enable driver for SMSC/LAN91x family of chips.

View file

@ -22,6 +22,8 @@ LOG_MODULE_REGISTER(mdio_shell, CONFIG_LOG_DEFAULT_LEVEL);
#define DT_DRV_COMPAT nxp_s32_netc_emdio
#elif DT_HAS_COMPAT_STATUS_OKAY(adi_adin2111_mdio)
#define DT_DRV_COMPAT adi_adin2111_mdio
#elif DT_HAS_COMPAT_STATUS_OKAY(smsc_lan91c111_mdio)
#define DT_DRV_COMPAT smsc_lan91c111_mdio
#else
#error "No known devicetree compatible match for MDIO shell"
#endif