Skip to content

Commit

Permalink
drivers: ethernet: stm32: add get_phy() support
Browse files Browse the repository at this point in the history
implementation of get_phy() added.

Signed-off-by: Ram Mahesh <rammaheshram1234@gmail.com>
  • Loading branch information
ramram885 committed Feb 9, 2025
1 parent 759e31d commit cbac85b
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions drivers/ethernet/eth_stm32_hal.c
Original file line number Diff line number Diff line change
Expand Up @@ -1252,6 +1252,12 @@ static int eth_stm32_hal_set_config(const struct device *dev,
return ret;
}

static const struct device *eth_stm32_hal_get_phy(const struct device *dev)
{
ARG_UNUSED(dev);
return eth_stm32_phy_dev;
}

#if defined(CONFIG_PTP_CLOCK_STM32_HAL)
static const struct device *eth_stm32_get_ptp_clock(const struct device *dev)
{
Expand All @@ -1277,6 +1283,7 @@ static const struct ethernet_api eth_api = {
#endif /* CONFIG_PTP_CLOCK_STM32_HAL */
.get_capabilities = eth_stm32_hal_get_capabilities,
.set_config = eth_stm32_hal_set_config,
.get_phy = eth_stm32_hal_get_phy,
#if defined(CONFIG_NET_DSA)
.send = dsa_tx,
#else
Expand Down

0 comments on commit cbac85b

Please sign in to comment.