]> git.baikalelectronics.ru Git - kernel.git/commit
ftgmac100: Cleanup speed/duplex tracking and fix duplex config
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>
Wed, 5 Apr 2017 02:28:45 +0000 (12:28 +1000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 6 Apr 2017 19:38:04 +0000 (12:38 -0700)
commiteba4afc10eacf331a887ef7604965f3ee85f24af
tree01ab3f62d26708f4b406284c18082f4712708624
parent82a407f966a571cc8691065421c5e096b2e7a7c7
ftgmac100: Cleanup speed/duplex tracking and fix duplex config

Keep track of both the current speed and duplex settings
instead of only speed and properly apply the duplex setting
to the HW.

This reworks the adjust_link() function to also avoid trying
to reconfigure the HW when there is no link and to display
the link state to the user.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/faraday/ftgmac100.c