]> git.baikalelectronics.ru Git - kernel.git/commit
net: phy: fixed_phy: set phy_mask before calling mdiobus_register()
authorRasmus Villemoes <linux@rasmusvillemoes.dk>
Mon, 6 Jun 2022 20:02:08 +0000 (22:02 +0200)
committerJakub Kicinski <kuba@kernel.org>
Tue, 14 Jun 2022 06:11:24 +0000 (23:11 -0700)
commitc9d2f21855758015edf8eb5b964fd718fa69278f
tree98b4b875fb8cc3ac05dcb97ba55a438b51151bc8
parentc3120f60f8bc211d5f72e88e6b22e5e153daa368
net: phy: fixed_phy: set phy_mask before calling mdiobus_register()

There's no point probing for phys on this artificial bus, so we can
save a little bit of boot time by telling mdiobus_register() not to do
that.

This doesn't have any functional change, since, at this point,
fixed_mdio_read() returns 0xffff for all addresses/registers, so

  mdiobus_scan() -> get_phy_device() -> get_phy_c22_id()

will return -ENODEV, which is just ignored.

Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
Link: https://lore.kernel.org/r/20220606200208.1665417-1-linux@rasmusvillemoes.dk
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/phy/fixed_phy.c