]> 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)
commit0755bb81ee88f1083f11b04fdb4431dd14b63340
tree01ab3f62d26708f4b406284c18082f4712708624
parent86ee3d8aad4faf802736b49d7f886929f218d778
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