]> git.baikalelectronics.ru Git - kernel.git/commit
sfc: Get rid of per-NIC-type phys_addr_channels and mem_map_size
authorBen Hutchings <bhutchings@solarflare.com>
Tue, 18 Sep 2012 23:56:47 +0000 (00:56 +0100)
committerBen Hutchings <bhutchings@solarflare.com>
Wed, 21 Aug 2013 19:20:42 +0000 (20:20 +0100)
commitfc6ea4ec59c0134d5c2ee58fd4d170a2e6269846
treec00496458c29a80cb3d66f1d9086e554fe6ab3d6
parent2e5c9018c3fe9a6081746fceb5b8dd47bee6748c
sfc: Get rid of per-NIC-type phys_addr_channels and mem_map_size

EF10 functions don't have a fixed BAR size, and the minimum is not
large enough for all the queues we might want to allocate.  We have to
find out the BAR size at run-time, and therefore phys_addr_channels
and mem_map_size cannot be defined per-NIC-type.

Change efx_nic_type::mem_map_size to a function pointer which is
called to find the wanted memory map size (before probe).

Replace efx_nic_type::phys_addr_channels with efx_nic::max_channels,
to be initialised by the probe function.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
drivers/net/ethernet/sfc/efx.c
drivers/net/ethernet/sfc/falcon.c
drivers/net/ethernet/sfc/net_driver.h
drivers/net/ethernet/sfc/siena.c