]> git.karo-electronics.de Git - linux-beck.git/commit
sfc: Simplify XMAC link polling
authorBen Hutchings <bhutchings@solarflare.com>
Wed, 25 Nov 2009 16:12:01 +0000 (16:12 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 26 Nov 2009 23:59:43 +0000 (15:59 -0800)
commit9007b9fa368b172e6b9a985899080fbebb7d3204
tree3d725a55e193fe9763fcd514a6b4246eae8da957
parentfe75820b99ff2de713de23252432f0f9d0ca1d35
sfc: Simplify XMAC link polling

From: Steve Hodgson <shodgson@solarflare.com>

Only the XMAC on Falcon needs help from the driver to poll and reset
the MAC-PHY link (XAUI); GMII is a simple parallel bus and on later
NICs firmware takes care of the XAUI link.  Also, an XMAC interrupt
currently schedules a work item which simply clears a flag
(efx_nic::mac_up) to be checked by the regular monitor (or the next
link reconfiguration, if that is sooner).

Rename the flag to xmac_poll_required, changing its sense.  Remove the
needless indirection and just set the flag immediately.  Call
falcon_xmac_poll() directly where required.

Add a new generic operation mac_op::check_fault to check the link
outside of regular monitoring, as required during self-tests.

(Note that this leaves us with an unused work item, but we will
immediately have another use for it.)

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/sfc/efx.c
drivers/net/sfc/falcon.c
drivers/net/sfc/falcon.h
drivers/net/sfc/falcon_boards.c
drivers/net/sfc/falcon_gmac.c
drivers/net/sfc/falcon_xmac.c
drivers/net/sfc/net_driver.h
drivers/net/sfc/selftest.c