linux/drivers/net
Florian Fainelli 536fab5bf5 net: dsa: bcm_sf2: Do not register slave MDIO bus with OF
We were registering our slave MDIO bus with OF and doing so with
assigning the newly created slave_mii_bus of_node to the master MDIO bus
controller node. This is a bad thing to do for a number of reasons:

- we are completely lying about the slave MII bus is arranged and yet we
  still want to control which MDIO devices it probes. It was attempted
  before to play tricks with the bus_mask to perform that:
  https://www.spinics.net/lists/netdev/msg429420.html but the approach
  was rightfully rejected

- the device_node reference counting is messed up and we are effectively
  doing a double probe on the devices we already probed using the
  master, this messes up all resources reference counts (such as clocks)

The proper fix for this as indicated by David in his reply to the
thread above is to use a platform data style registration so as to
control exactly which devices we probe:
https://www.spinics.net/lists/netdev/msg430083.html

By using mdiobus_register(), our slave_mii_bus->phy_mask value is used
as intended, and all the PHY addresses that must be redirected towards
our slave MDIO bus is happening while other addresses get redirected
towards the master MDIO bus.

Fixes: 461cd1b03e ("net: dsa: bcm_sf2: Register our slave MDIO bus")
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Vivien Didelot <vivien.didelot@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2020-04-06 10:07:37 -07:00
..
appletalk
arcnet
bonding Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-03-12 22:34:48 -07:00
caif net: caif: Use scnprintf() for avoiding potential buffer overflow 2020-03-15 17:06:22 -07:00
can slcan: Don't transmit uninitialized stack data in padding 2020-04-01 11:22:35 -07:00
dsa net: dsa: bcm_sf2: Do not register slave MDIO bus with OF 2020-04-06 10:07:37 -07:00
ethernet net: stmmac: dwmac1000: fix out-of-bounds mac address reg setting 2020-04-03 15:58:54 -07:00
fddi
fjes
hamradio
hippi
hyperv hv_netvsc: Remove unnecessary round_up for recv_completion_cnt 2020-03-30 19:43:42 -07:00
ieee802154
ipa soc: qcom: ipa: kill IPA_RX_BUFFER_ORDER 2020-03-21 19:46:43 -07:00
ipvlan ipvlan: do not use cond_resched_rcu() in ipvlan_process_multicast() 2020-03-09 18:32:03 -07:00
netdevsim netdevsim: dev: Fix memory leak in nsim_dev_take_snapshot_write 2020-03-30 20:14:22 -07:00
phy net: phy: micrel: kszphy_resume(): add delay after genphy_resume() before accessing PHY registers 2020-04-03 16:04:24 -07:00
plip
ppp
slip Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-03-12 22:34:48 -07:00
team
usb pegasus: Remove pegasus' own workqueue 2020-04-02 17:58:25 -07:00
vmxnet3
wan Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next 2020-03-31 17:29:33 -07:00
wimax
wireguard net: Fix CONFIG_NET_CLS_ACT=n and CONFIG_NFT_FWD_NETDEV={y, m} build 2020-03-25 12:24:33 -07:00
wireless Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next 2020-03-31 17:29:33 -07:00
xen-netback
bareudp.c bareudp: Fixed bareudp receive handling 2020-03-11 22:54:27 -07:00
dummy.c
eql.c
geneve.c geneve: move debug check after netdev unregister 2020-03-15 00:42:35 -07:00
gtp.c
ifb.c net: Fix CONFIG_NET_CLS_ACT=n and CONFIG_NFT_FWD_NETDEV={y, m} build 2020-03-25 12:24:33 -07:00
Kconfig Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-03-25 18:58:11 -07:00
LICENSE.SRC
loopback.c
macsec.c net: macsec: add support for specifying offload upon link creation 2020-03-29 21:34:21 -07:00
macvlan.c macvlan: add cond_resched() during multicast processing 2020-03-09 18:02:19 -07:00
macvtap.c
Makefile soc: qcom: ipa: support build of IPA code 2020-03-08 22:07:10 -07:00
mdio.c
mii.c
net_failover.c
netconsole.c
nlmon.c
ntb_netdev.c
rionet.c
sb1000.c
Space.c
sungem_phy.c
tap.c
thunderbolt.c
tun.c tun: Don't put_page() for all negative return values from XDP program 2020-04-06 10:00:43 -07:00
veth.c veth: rely on peer veth_rq for ndo_xdp_xmit accounting 2020-03-26 19:35:13 -07:00
virtio_net.c
vrf.c Remove DST_HOST 2020-03-23 21:57:44 -07:00
vsockmon.c
vxlan.c vxlan: check return value of gro_cells_init() 2020-03-18 16:43:12 -07:00
xen-netfront.c