android_kernel_xiaomi_sm7250/drivers/net/phy
Guangbin Huang acf0610a2d net: phy: fix save wrong speed and duplex problem if autoneg is on
[ Upstream commit d9032dba5a2b2bbf0fdce67c8795300ec9923b43 ]

If phy uses generic driver and autoneg is on, enter command
"ethtool -s eth0 speed 50" will not change phy speed actually, but
command "ethtool eth0" shows speed is 50Mb/s because phydev->speed
has been set to 50 and no update later.

And duplex setting has same problem too.

However, if autoneg is on, phy only changes speed and duplex according to
phydev->advertising, but not phydev->speed and phydev->duplex. So in this
case, phydev->speed and phydev->duplex don't need to be set in function
phy_ethtool_ksettings_set() if autoneg is on.

Fixes: 51e2a3846e ("PHY: Avoid unnecessary aneg restarts")
Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com>
Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-03-17 16:43:45 +01:00
..
amd.c
aquantia.c
at803x.c
ax88796b.c
bcm7xxx.c
bcm63xx.c
bcm87xx.c
bcm-cygnus.c
bcm-phy-lib.c
bcm-phy-lib.h
broadcom.c
cicada.c
cortina.c
davicom.c
dp83tc811.c
dp83640_reg.h
dp83640.c net: dp83640: fix SIOCSHWTSTAMP to update the struct with actual configuration 2020-07-29 10:16:49 +02:00
dp83822.c
dp83848.c
dp83867.c net: phy: dp83867: enable robust auto-mdix 2019-12-31 16:35:27 +01:00
et1011c.c
fixed_phy.c net: phy: fixed_phy: Fix fixed_phy not checking GPIO 2020-01-27 14:50:20 +01:00
icplus.c
intel-xway.c
Kconfig mdio: fix mdio-thunder.c dependency & build error 2020-10-14 10:31:25 +02:00
lxt.c
Makefile
marvell10g.c
marvell.c
mdio_bus.c mdio_bus: Fix PTR_ERR() usage after initialization to constant 2020-01-27 14:50:24 +01:00
mdio_device.c
mdio-bcm-iproc.c net: phy: restore mdio regs in the iproc mdio driver 2020-03-05 16:42:16 +01:00
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-i2c.c
mdio-i2c.h
mdio-moxart.c
mdio-mscc-miim.c
mdio-mux-bcm-iproc.c net: phy: mdio-mux-bcm-iproc: check clk_prepare_enable() return value 2020-04-02 15:28:13 +02:00
mdio-mux-gpio.c
mdio-mux-mmioreg.c
mdio-mux.c
mdio-octeon.c
mdio-sun4i.c
mdio-thunder.c
mdio-xgene.c
mdio-xgene.h
meson-gxl.c
micrel.c net: phy: micrel: kszphy_resume(): add delay after genphy_resume() before accessing PHY registers 2020-04-13 10:45:08 +02:00
microchip_t1.c
microchip.c
mscc.c
national.c
phy_device.c net: phy: Avoid NPD upon phy_detach() when driver is unbound 2020-09-26 18:01:30 +02:00
phy_led_triggers.c
phy-c45.c
phy-core.c
phy.c net: phy: fix save wrong speed and duplex problem if autoneg is on 2021-03-17 16:43:45 +01:00
phylink.c
qsemi.c
realtek.c
rockchip.c
sfp-bus.c net: sfp: add some quirks for GPON modules 2020-07-22 09:32:03 +02:00
sfp.c sfp: Fix error handing in sfp_probe() 2020-11-10 12:35:54 +01:00
sfp.h
smsc.c
spi_ks8995.c
ste10Xp.c
swphy.c
swphy.h
teranetics.c
uPD60620.c
vitesse.c
xilinx_gmii2rgmii.c