alistair23-linux/drivers/net/phy
Martin Blumenstingl 457839ed3e mdio: mux: fix parsing mux registers outside of the PHY address range
mdio_mux_init parses the child nodes of the MDIO mux. When using
"mdio-mux-mmioreg" the child nodes are describing the register value
that is written to switch between the MDIO busses.

The change which makes the error messages more verbose changed the
parsing of the "reg" property from a simple of_property_read_u32 call
to of_mdio_parse_addr. On a Khadas VIM (based on the Meson GXL SoC,
which uses mdio-mux-mmioreg) this prevents registering the MDIO mux
(because the "reg" values on the MDIO mux child nodes are 0x2009087f
and 0xe40908ff) and leads to the following errors:
  mdio-mux-mmioreg c883455c.eth-phy-mux: /soc/periphs@c8834000/eth-phy-mux/mdio@e40908ff PHY address -469169921 is too large
  mdio-mux-mmioreg c883455c.eth-phy-mux: Error: Failed to find reg for child /soc/periphs@c8834000/eth-phy-mux/mdio@e40908ff
  mdio-mux-mmioreg c883455c.eth-phy-mux: /soc/periphs@c8834000/eth-phy-mux/mdio@2009087f PHY address 537462911 is too large
  mdio-mux-mmioreg c883455c.eth-phy-mux: Error: Failed to find reg for child /soc/periphs@c8834000/eth-phy-mux/mdio@2009087f
  mdio-mux-mmioreg c883455c.eth-phy-mux: Error: No acceptable child buses found
  mdio-mux-mmioreg c883455c.eth-phy-mux: failed to register mdio-mux bus /soc/periphs@c8834000/eth-phy-mux
(as a result of that ethernet is not working, because the PHY which is
connected through the mux' child MDIO bus, which is not being
registered).

Fix this by reverting the change from of_mdio_parse_addr to
of_mdio_parse_addr.

Fixes: 342fa19644 ("mdio: mux: make child bus walking more permissive and errors more verbose")
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Acked-by: Neil Armstrong <narmstrong@baylibre.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-07-14 08:12:45 -07:00
..
amd.c
aquantia.c
at803x.c
bcm-cygnus.c
bcm-phy-lib.c
bcm-phy-lib.h
bcm7xxx.c
bcm63xx.c
bcm87xx.c
broadcom.c net: phy: Remove residual magic from PHY drivers 2017-05-16 15:58:18 -04:00
cicada.c
cortina.c net: phy: Add Cortina CS4340 driver 2017-05-30 12:42:27 -04:00
davicom.c
dp83640.c net: dp83640: Avoid NULL pointer dereference. 2017-06-23 14:38:16 -04:00
dp83640_reg.h
dp83848.c
dp83867.c net: phy: dp83867: add workaround for incorrect RX_CTRL pin strap 2017-07-05 09:23:53 +01:00
et1011c.c
fixed_phy.c
icplus.c
intel-xway.c
Kconfig Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-06-15 11:59:32 -04:00
lxt.c net: phy: lxt: Export link partner advertising 2017-06-20 13:41:24 -04:00
Makefile net: phy: add Marvell Alaska X 88X3310 10Gigabit PHY support 2017-06-06 21:14:13 -04:00
marvell.c net: phy: Add phy loopback support in net phy framework 2017-07-03 02:01:15 -07:00
marvell10g.c net: phy: add Marvell Alaska X 88X3310 10Gigabit PHY support 2017-06-06 21:14:13 -04:00
mdio-bcm-iproc.c
mdio-bcm-unimac.c
mdio-bitbang.c
mdio-boardinfo.c
mdio-boardinfo.h
mdio-cavium.c
mdio-cavium.h
mdio-gpio.c
mdio-hisi-femac.c
mdio-moxart.c
mdio-mux-bcm-iproc.c net: mdio-mux: bcm-iproc: call mdiobus_free() in error path 2017-05-08 17:59:33 -04:00
mdio-mux-gpio.c
mdio-mux-mmioreg.c
mdio-mux.c mdio: mux: fix parsing mux registers outside of the PHY address range 2017-07-14 08:12:45 -07:00
mdio-octeon.c
mdio-sun4i.c
mdio-thunder.c
mdio-xgene.c drivers: net: phy: xgene: Add lock to protect mac access 2017-05-16 11:41:08 -04:00
mdio-xgene.h drivers: net: phy: xgene: Add lock to protect mac access 2017-05-16 11:41:08 -04:00
mdio_bus.c mdio_bus: use devm_gpiod_get_optional() 2017-06-13 12:56:42 -04:00
mdio_device.c
meson-gxl.c
micrel.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-06-30 12:43:08 -04:00
microchip.c net: phy: Remove residual magic from PHY drivers 2017-05-16 15:58:18 -04:00
mscc.c
national.c
phy-c45.c net: phy: split out 10G genphy support 2017-06-06 21:14:13 -04:00
phy-core.c
phy.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2017-07-05 12:31:59 -07:00
phy_device.c net: phy: Add phy loopback support in net phy framework 2017-07-03 02:01:15 -07:00
phy_led_triggers.c
qsemi.c
realtek.c
smsc.c net: phy: smsc: fix buffer overflow in memcpy 2017-06-22 11:12:31 -04:00
spi_ks8995.c
ste10Xp.c
swphy.c
swphy.h
teranetics.c
vitesse.c
xilinx_gmii2rgmii.c