lin
2025-07-30 fcd736bf35fd93b563e9bbf594f2aa7b62028cc9
longan/kernel/linux-4.9/drivers/net/phy/phy_device.c
....@@ -487,6 +487,15 @@
487487 if (is_c45)
488488 return get_phy_c45_ids(bus, addr, phy_id, c45_ids);
489489
490
+#ifdef CONFIG_MAXIO_PHY
491
+ /*
492
+ *An MDIO connects to multiple PHYs requiring write before read.
493
+ *This operation does not affect one MDIO connected to a single PHY
494
+ *MII_PHYSID2 is a read-only register and writine to it has no effect
495
+ */
496
+ mdiobus_write(bus,addr,MII_PHYSID2,0);
497
+#endif
498
+
490499 /* Grab the bits from PHYIR1, and put them in the upper half */
491500 phy_reg = mdiobus_read(bus, addr, MII_PHYSID1);
492501 if (phy_reg < 0)