iwlwifi: dynamically determine lib_ops

Having the pointer to lib_ops in the config
makes it impossible to split the driver into
different modules. Determine the ops based on
the device family enumeration to get rid of
the direct pointer.

Also move all the opmode specific code from
the iwl-[1256]000.c files into a new file
iwl-agn-devices.c so that the former only
have configuration data now.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
Johannes Berg
2012-04-10 14:10:28 -07:00
committed by John W. Linville
parent a141e6a009
commit e96766958c
14 changed files with 763 additions and 736 deletions

View File

@@ -66,8 +66,6 @@
#include <linux/types.h>
#include <net/mac80211.h>
struct iwl_lib_ops;
enum iwl_device_family {
IWL_DEVICE_FAMILY_UNDEFINED,
@@ -212,7 +210,6 @@ struct iwl_cfg {
u8 valid_rx_ant;
u16 eeprom_ver;
u16 eeprom_calib_ver;
const struct iwl_lib_ops *lib;
/* params not likely to change within a device family */
const struct iwl_base_params *base_params;
/* params likely to change within a device family */