net: octeontx: smi: fix mii probe
authorTim Harvey <tharvey@gateworks.com>
Fri, 26 Mar 2021 00:07:37 +0000 (17:07 -0700)
committerTom Rini <trini@konsulko.com>
Tue, 20 Apr 2021 11:31:12 +0000 (07:31 -0400)
The fdt node offset is apparently not set properly when probed
causing no MDIO busses to be found. Fix this by obtaining the
offset.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Stefan Roese <sr@denx.de>
drivers/net/octeontx/smi.c

index 91dcd05..27f4423 100644 (file)
@@ -325,6 +325,8 @@ int octeontx_smi_probe(struct udevice *dev)
                return -1;
        }
 
+       node = fdt_node_offset_by_compatible(gd->fdt_blob, -1,
+                                            "cavium,thunder-8890-mdio-nexus");
        fdt_for_each_subnode(subnode, gd->fdt_blob, node) {
                ret = fdt_node_check_compatible(gd->fdt_blob, subnode,
                                                "cavium,thunder-8890-mdio");