]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
net: phy: marvell: consolidate phy status reading
authorRussell King <rmk+kernel@armlinux.org.uk>
Tue, 17 Dec 2019 13:39:36 +0000 (13:39 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 19 Dec 2019 20:52:34 +0000 (12:52 -0800)
commitd2004e27eb352a5961cae7cc50563dbdc5386ba7
treeacd52e665ac63ab483a98f6b70f2d5f8f4ba4fb5
parent760fa78f3509d3d414804c4017de3d0dba995081
net: phy: marvell: consolidate phy status reading

marvell_read_status_page_an() always reads the PHY status register, but
marvell_update_link() has already done this.  Rather than wastefully
reading the register twice in quick succession, read it once in
marvell_read_status_page() and use the result for both.

This makes marvell_update_link() rather pointless, so move it into
marvell_read_status_page().

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/marvell.c