OSDN Git Service

sfc: Merge efx_mac_operations into efx_nic_type
authorBen Hutchings <bhutchings@solarflare.com>
Fri, 2 Sep 2011 23:15:00 +0000 (00:15 +0100)
committerBen Hutchings <bhutchings@solarflare.com>
Fri, 27 Jan 2012 00:10:46 +0000 (00:10 +0000)
commit710b208dc2687fdb3370110d54a67fb2288835eb
treeb6a403a44f7832a469e31f91121e3eb2cff78c68
parent1cb345220f135dcca24f01cc04cbb97a8242d419
sfc: Merge efx_mac_operations into efx_nic_type

No NICs need to switch efx_mac_operations at run-time, and the MAC
operations are fairly closely bound to NIC types.

Move efx_mac_operations::reconfigure to efx_nic_type::reconfigure_mac
and efx_mac_operations::check_fault fo efx_nic_type::check_mac_fault.
Change callers to call through efx->type or directly if the NIC type
is known.

Remove efx_mac_operations::update_stats.  The implementations for
Falcon used to fetch MAC statistics synchronously and this was used by
efx_register_netdev() to clear statistics after running self-tests.
However, it now only converts statistics that have already been
fetched (and that only for Falcon), and the call from
efx_register_netdev() has no effect.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
drivers/net/ethernet/sfc/efx.c
drivers/net/ethernet/sfc/ethtool.c
drivers/net/ethernet/sfc/falcon.c
drivers/net/ethernet/sfc/falcon_xmac.c
drivers/net/ethernet/sfc/mac.h [deleted file]
drivers/net/ethernet/sfc/mcdi.h
drivers/net/ethernet/sfc/mcdi_mac.c
drivers/net/ethernet/sfc/net_driver.h
drivers/net/ethernet/sfc/nic.h
drivers/net/ethernet/sfc/selftest.c
drivers/net/ethernet/sfc/siena.c