drivers: ethernet: stm32: Allow disabling carrier checking
On Zephyr devices that has an Ethernet switch IC with the Zephyr device
connected to the CPU port, there aren't necessarilly any register to
check the link state on that port. If the check is kept on such devices,
Zephyr will believe the link disappears
CONFIG_ETH_STM32_CARRIER_CHECK_RX_IDLE_TIMEOUT_MS after last message was
received, until a new message is received. If the application tries to
send data while the link is considered gone, sending returns an error,
sometimes indicating that the interface is down.
It also seems conceptually meaningless to try determining link state on
such devices, since as long as both the microcontroller and the switch
IC is powered, the link should always be up.
This commit therefore introduces a new Kconfig to allow disabling the
entire checking of link state, so that on devices where there is no
relevant PHY register to read, the check can be disabled.
Signed-off-by: Ole Morten Haaland <omh@ixys.no>
2 files changed