Re: [PATCH net-next v2 2/2] net: stmmac: Add glue layer for Synaptics SL2610 SoC
From: Andrew Lunn
Date: Mon Nov 30 2026 - 14:53:05 EST
> +static int syna_dwmac_init(struct device *dev, void *priv)
> +{
> + struct syna_dwmac *dwmac = priv;
> + u32 mdio_sel;
> +
> + /* Only the MAC providing the shared MDIO bus selects its master. */
> + if (!dwmac->plat->mdio_node ||
> + !of_device_is_available(dwmac->plat->mdio_node))
> + return 0;
I think it would be good to have some sort of validation here, that if
both MACs have an available mdio node, the probe of the second one
fails with EINVAL and an error messages.
Andrew