]> git.baikalelectronics.ru Git - kernel.git/commit
r8169: fix page read in r8168g_mdio_read
authorHeiner Kallweit <hkallweit1@gmail.com>
Wed, 6 Nov 2019 20:51:31 +0000 (21:51 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 7 Nov 2019 05:36:48 +0000 (21:36 -0800)
commit14dd229c7bfae21fd04b21913b9b76b0c0616f20
tree20c2f559740a428af9a7523f996f9724b1eab41b
parentdd9ede3c5222343372d0086fddfb935f0f55f3c0
r8169: fix page read in r8168g_mdio_read

Functions like phy_modify_paged() read the current page, on Realtek
PHY's this means reading the value of register 0x1f. Add special
handling for reading this register, similar to what we do already
in r8168g_mdio_write(). Currently we read a random value that by
chance seems to be 0 always.

Fixes: 1ef4f7d22178 ("r8169: use paged versions of phylib MDIO access functions")
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/realtek/r8169_main.c