diff options
author | David S. Miller <davem@davemloft.net> | 2021-09-21 13:52:16 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-09-21 13:52:16 +0100 |
commit | b3f98404bd629a243c0a15a3ade32b1cf9fbe0da (patch) | |
tree | 47d513bd1a6faead4589b3f42467ff81e0148fb5 /lib/crc4.c | |
parent | 3e95cfa24e24fbd7fb7675ab972a5aa507c7a89c (diff) | |
parent | 74b6d7d13307b016f4b5bba8198297824c0ee6df (diff) |
Merge branch 'dsa-devres'
Vladimir Oltean says:
====================
Fix mdiobus users with devres
Commit ac3a68d56651 ("net: phy: don't abuse devres in
devm_mdiobus_register()") by Bartosz Golaszewski has introduced two
classes of potential bugs by making the devres callback of
devm_mdiobus_alloc stop calling mdiobus_unregister.
The exact buggy circumstances are presented in the individual commit
messages. I have searched the tree for other occurrences, but at the
moment:
- for issue (a) I have no concrete proof that other buses except SPI and
I2C suffer from it, and the only SPI or I2C device drivers that call
of_mdiobus_alloc are the DSA drivers that leave a NULL
ds->slave_mii_bus and a non-NULL ds->ops->phy_read, aka ksz9477,
ksz8795, lan9303_i2c, vsc73xx-spi.
- for issue (b), all drivers which call of_mdiobus_alloc either use
of_mdiobus_register too, or call mdiobus_unregister sometime within
the ->remove path.
Although at this point I've seen enough strangeness caused by this
"device_del during ->shutdown" that I'm just going to copy the SPI and
I2C subsystem maintainers to this patch series, to get their feedback
whether they've had reports about things like this before. I don't think
other buses behave in this way, it forces SPI and I2C devices to have to
protect themselves from a really strange set of issues.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'lib/crc4.c')
0 files changed, 0 insertions, 0 deletions