aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/iwlwifi')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-1000.c1
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-3945.c1
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-3945.h2
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-4965.c1
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-5000.c2
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-6000.c4
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-agn.c6
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-agn.h2
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-core.c10
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-core.h4
-rw-r--r--drivers/net/wireless/iwlwifi/iwl3945-base.c4
11 files changed, 25 insertions, 12 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-1000.c b/drivers/net/wireless/iwlwifi/iwl-1000.c
index db540910b110..4266c855a767 100644
--- a/drivers/net/wireless/iwlwifi/iwl-1000.c
+++ b/drivers/net/wireless/iwlwifi/iwl-1000.c
@@ -243,6 +243,7 @@ static const struct iwl_ops iwl1000_ops = {
243 .hcmd = &iwlagn_hcmd, 243 .hcmd = &iwlagn_hcmd,
244 .utils = &iwlagn_hcmd_utils, 244 .utils = &iwlagn_hcmd_utils,
245 .led = &iwlagn_led_ops, 245 .led = &iwlagn_led_ops,
246 .ieee80211_ops = &iwlagn_hw_ops,
246}; 247};
247 248
248static struct iwl_base_params iwl1000_base_params = { 249static struct iwl_base_params iwl1000_base_params = {
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.c b/drivers/net/wireless/iwlwifi/iwl-3945.c
index 4d7130c9b72c..95fed1158452 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945.c
+++ b/drivers/net/wireless/iwlwifi/iwl-3945.c
@@ -2753,6 +2753,7 @@ static const struct iwl_ops iwl3945_ops = {
2753 .hcmd = &iwl3945_hcmd, 2753 .hcmd = &iwl3945_hcmd,
2754 .utils = &iwl3945_hcmd_utils, 2754 .utils = &iwl3945_hcmd_utils,
2755 .led = &iwl3945_led_ops, 2755 .led = &iwl3945_led_ops,
2756 .ieee80211_ops = &iwl3945_hw_ops,
2756}; 2757};
2757 2758
2758static struct iwl_base_params iwl3945_base_params = { 2759static struct iwl_base_params iwl3945_base_params = {
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.h b/drivers/net/wireless/iwlwifi/iwl-3945.h
index 09391f0ee61f..b27f07cbf355 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945.h
+++ b/drivers/net/wireless/iwlwifi/iwl-3945.h
@@ -282,6 +282,8 @@ extern int iwl3945_commit_rxon(struct iwl_priv *priv,
282 */ 282 */
283extern u8 iwl3945_hw_find_station(struct iwl_priv *priv, const u8 *bssid); 283extern u8 iwl3945_hw_find_station(struct iwl_priv *priv, const u8 *bssid);
284 284
285extern struct ieee80211_ops iwl3945_hw_ops;
286
285/* 287/*
286 * Forward declare iwl-3945.c functions for iwl-base.c 288 * Forward declare iwl-3945.c functions for iwl-base.c
287 */ 289 */
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965.c b/drivers/net/wireless/iwlwifi/iwl-4965.c
index ee9c582c8cf2..7921a910b34a 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965.c
+++ b/drivers/net/wireless/iwlwifi/iwl-4965.c
@@ -2305,6 +2305,7 @@ static const struct iwl_ops iwl4965_ops = {
2305 .hcmd = &iwl4965_hcmd, 2305 .hcmd = &iwl4965_hcmd,
2306 .utils = &iwl4965_hcmd_utils, 2306 .utils = &iwl4965_hcmd_utils,
2307 .led = &iwlagn_led_ops, 2307 .led = &iwlagn_led_ops,
2308 .ieee80211_ops = &iwlagn_hw_ops,
2308}; 2309};
2309 2310
2310static struct iwl_base_params iwl4965_base_params = { 2311static struct iwl_base_params iwl4965_base_params = {
diff --git a/drivers/net/wireless/iwlwifi/iwl-5000.c b/drivers/net/wireless/iwlwifi/iwl-5000.c
index fd9fbc93ea1b..5f0327721692 100644
--- a/drivers/net/wireless/iwlwifi/iwl-5000.c
+++ b/drivers/net/wireless/iwlwifi/iwl-5000.c
@@ -485,6 +485,7 @@ static const struct iwl_ops iwl5000_ops = {
485 .hcmd = &iwlagn_hcmd, 485 .hcmd = &iwlagn_hcmd,
486 .utils = &iwlagn_hcmd_utils, 486 .utils = &iwlagn_hcmd_utils,
487 .led = &iwlagn_led_ops, 487 .led = &iwlagn_led_ops,
488 .ieee80211_ops = &iwlagn_hw_ops,
488}; 489};
489 490
490static const struct iwl_ops iwl5150_ops = { 491static const struct iwl_ops iwl5150_ops = {
@@ -492,6 +493,7 @@ static const struct iwl_ops iwl5150_ops = {
492 .hcmd = &iwlagn_hcmd, 493 .hcmd = &iwlagn_hcmd,
493 .utils = &iwlagn_hcmd_utils, 494 .utils = &iwlagn_hcmd_utils,
494 .led = &iwlagn_led_ops, 495 .led = &iwlagn_led_ops,
496 .ieee80211_ops = &iwlagn_hw_ops,
495}; 497};
496 498
497static struct iwl_base_params iwl5000_base_params = { 499static struct iwl_base_params iwl5000_base_params = {
diff --git a/drivers/net/wireless/iwlwifi/iwl-6000.c b/drivers/net/wireless/iwlwifi/iwl-6000.c
index 11e6532fc573..85bde701351e 100644
--- a/drivers/net/wireless/iwlwifi/iwl-6000.c
+++ b/drivers/net/wireless/iwlwifi/iwl-6000.c
@@ -439,6 +439,7 @@ static const struct iwl_ops iwl6000_ops = {
439 .hcmd = &iwlagn_hcmd, 439 .hcmd = &iwlagn_hcmd,
440 .utils = &iwlagn_hcmd_utils, 440 .utils = &iwlagn_hcmd_utils,
441 .led = &iwlagn_led_ops, 441 .led = &iwlagn_led_ops,
442 .ieee80211_ops = &iwlagn_hw_ops,
442}; 443};
443 444
444static const struct iwl_ops iwl6050_ops = { 445static const struct iwl_ops iwl6050_ops = {
@@ -447,6 +448,7 @@ static const struct iwl_ops iwl6050_ops = {
447 .utils = &iwlagn_hcmd_utils, 448 .utils = &iwlagn_hcmd_utils,
448 .led = &iwlagn_led_ops, 449 .led = &iwlagn_led_ops,
449 .nic = &iwl6050_nic_ops, 450 .nic = &iwl6050_nic_ops,
451 .ieee80211_ops = &iwlagn_hw_ops,
450}; 452};
451 453
452static const struct iwl_ops iwl6050g2_ops = { 454static const struct iwl_ops iwl6050g2_ops = {
@@ -455,6 +457,7 @@ static const struct iwl_ops iwl6050g2_ops = {
455 .utils = &iwlagn_hcmd_utils, 457 .utils = &iwlagn_hcmd_utils,
456 .led = &iwlagn_led_ops, 458 .led = &iwlagn_led_ops,
457 .nic = &iwl6050g2_nic_ops, 459 .nic = &iwl6050g2_nic_ops,
460 .ieee80211_ops = &iwlagn_hw_ops,
458}; 461};
459 462
460static const struct iwl_ops iwl6000g2b_ops = { 463static const struct iwl_ops iwl6000g2b_ops = {
@@ -462,6 +465,7 @@ static const struct iwl_ops iwl6000g2b_ops = {
462 .hcmd = &iwlagn_bt_hcmd, 465 .hcmd = &iwlagn_bt_hcmd,
463 .utils = &iwlagn_hcmd_utils, 466 .utils = &iwlagn_hcmd_utils,
464 .led = &iwlagn_led_ops, 467 .led = &iwlagn_led_ops,
468 .ieee80211_ops = &iwlagn_hw_ops,
465}; 469};
466 470
467static struct iwl_base_params iwl6000_base_params = { 471static struct iwl_base_params iwl6000_base_params = {
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c
index 0027bb8299a8..e3533a89ec9c 100644
--- a/drivers/net/wireless/iwlwifi/iwl-agn.c
+++ b/drivers/net/wireless/iwlwifi/iwl-agn.c
@@ -4211,7 +4211,7 @@ static void iwl_uninit_drv(struct iwl_priv *priv)
4211 kfree(priv->scan_cmd); 4211 kfree(priv->scan_cmd);
4212} 4212}
4213 4213
4214static struct ieee80211_ops iwl_hw_ops = { 4214struct ieee80211_ops iwlagn_hw_ops = {
4215 .tx = iwl_mac_tx, 4215 .tx = iwl_mac_tx,
4216 .start = iwl_mac_start, 4216 .start = iwl_mac_start,
4217 .stop = iwl_mac_stop, 4217 .stop = iwl_mac_stop,
@@ -4300,10 +4300,10 @@ static int iwl_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
4300 if (cfg->mod_params->disable_hw_scan) { 4300 if (cfg->mod_params->disable_hw_scan) {
4301 dev_printk(KERN_DEBUG, &(pdev->dev), 4301 dev_printk(KERN_DEBUG, &(pdev->dev),
4302 "sw scan support is deprecated\n"); 4302 "sw scan support is deprecated\n");
4303 iwl_hw_ops.hw_scan = NULL; 4303 iwlagn_hw_ops.hw_scan = NULL;
4304 } 4304 }
4305 4305
4306 hw = iwl_alloc_all(cfg, &iwl_hw_ops); 4306 hw = iwl_alloc_all(cfg);
4307 if (!hw) { 4307 if (!hw) {
4308 err = -ENOMEM; 4308 err = -ENOMEM;
4309 goto out; 4309 goto out;
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.h b/drivers/net/wireless/iwlwifi/iwl-agn.h
index f525d55f2c0f..ba88e78e6116 100644
--- a/drivers/net/wireless/iwlwifi/iwl-agn.h
+++ b/drivers/net/wireless/iwlwifi/iwl-agn.h
@@ -102,6 +102,8 @@ extern struct iwl_hcmd_ops iwlagn_hcmd;
102extern struct iwl_hcmd_ops iwlagn_bt_hcmd; 102extern struct iwl_hcmd_ops iwlagn_bt_hcmd;
103extern struct iwl_hcmd_utils_ops iwlagn_hcmd_utils; 103extern struct iwl_hcmd_utils_ops iwlagn_hcmd_utils;
104 104
105extern struct ieee80211_ops iwlagn_hw_ops;
106
105int iwl_reset_ict(struct iwl_priv *priv); 107int iwl_reset_ict(struct iwl_priv *priv);
106void iwl_disable_ict(struct iwl_priv *priv); 108void iwl_disable_ict(struct iwl_priv *priv);
107int iwl_alloc_isr_ict(struct iwl_priv *priv); 109int iwl_alloc_isr_ict(struct iwl_priv *priv);
diff --git a/drivers/net/wireless/iwlwifi/iwl-core.c b/drivers/net/wireless/iwlwifi/iwl-core.c
index 2a4d40e5b9f4..c93368083e1a 100644
--- a/drivers/net/wireless/iwlwifi/iwl-core.c
+++ b/drivers/net/wireless/iwlwifi/iwl-core.c
@@ -77,15 +77,15 @@ EXPORT_SYMBOL(iwl_bcast_addr);
77 77
78 78
79/* This function both allocates and initializes hw and priv. */ 79/* This function both allocates and initializes hw and priv. */
80struct ieee80211_hw *iwl_alloc_all(struct iwl_cfg *cfg, 80struct ieee80211_hw *iwl_alloc_all(struct iwl_cfg *cfg)
81 struct ieee80211_ops *hw_ops)
82{ 81{
83 struct iwl_priv *priv; 82 struct iwl_priv *priv;
84
85 /* mac80211 allocates memory for this device instance, including 83 /* mac80211 allocates memory for this device instance, including
86 * space for this driver's private structure */ 84 * space for this driver's private structure */
87 struct ieee80211_hw *hw = 85 struct ieee80211_hw *hw;
88 ieee80211_alloc_hw(sizeof(struct iwl_priv), hw_ops); 86
87 hw = ieee80211_alloc_hw(sizeof(struct iwl_priv),
88 cfg->ops->ieee80211_ops);
89 if (hw == NULL) { 89 if (hw == NULL) {
90 pr_err("%s: Can not allocate network device\n", 90 pr_err("%s: Can not allocate network device\n",
91 cfg->name); 91 cfg->name);
diff --git a/drivers/net/wireless/iwlwifi/iwl-core.h b/drivers/net/wireless/iwlwifi/iwl-core.h
index b17de8214eb5..917d42eae55a 100644
--- a/drivers/net/wireless/iwlwifi/iwl-core.h
+++ b/drivers/net/wireless/iwlwifi/iwl-core.h
@@ -241,6 +241,7 @@ struct iwl_ops {
241 const struct iwl_hcmd_utils_ops *utils; 241 const struct iwl_hcmd_utils_ops *utils;
242 const struct iwl_led_ops *led; 242 const struct iwl_led_ops *led;
243 const struct iwl_nic_ops *nic; 243 const struct iwl_nic_ops *nic;
244 const struct ieee80211_ops *ieee80211_ops;
244}; 245};
245 246
246struct iwl_mod_params { 247struct iwl_mod_params {
@@ -396,8 +397,7 @@ struct iwl_cfg {
396 * L i b * 397 * L i b *
397 ***************************/ 398 ***************************/
398 399
399struct ieee80211_hw *iwl_alloc_all(struct iwl_cfg *cfg, 400struct ieee80211_hw *iwl_alloc_all(struct iwl_cfg *cfg);
400 struct ieee80211_ops *hw_ops);
401int iwl_mac_conf_tx(struct ieee80211_hw *hw, u16 queue, 401int iwl_mac_conf_tx(struct ieee80211_hw *hw, u16 queue,
402 const struct ieee80211_tx_queue_params *params); 402 const struct ieee80211_tx_queue_params *params);
403int iwl_mac_tx_last_beacon(struct ieee80211_hw *hw); 403int iwl_mac_tx_last_beacon(struct ieee80211_hw *hw);
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c
index 9b71921dc2b6..d42bb22e5ed5 100644
--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
@@ -3824,7 +3824,7 @@ static struct attribute_group iwl3945_attribute_group = {
3824 .attrs = iwl3945_sysfs_entries, 3824 .attrs = iwl3945_sysfs_entries,
3825}; 3825};
3826 3826
3827static struct ieee80211_ops iwl3945_hw_ops = { 3827struct ieee80211_ops iwl3945_hw_ops = {
3828 .tx = iwl3945_mac_tx, 3828 .tx = iwl3945_mac_tx,
3829 .start = iwl3945_mac_start, 3829 .start = iwl3945_mac_start,
3830 .stop = iwl3945_mac_stop, 3830 .stop = iwl3945_mac_stop,
@@ -3966,7 +3966,7 @@ static int iwl3945_pci_probe(struct pci_dev *pdev, const struct pci_device_id *e
3966 3966
3967 /* mac80211 allocates memory for this device instance, including 3967 /* mac80211 allocates memory for this device instance, including
3968 * space for this driver's private structure */ 3968 * space for this driver's private structure */
3969 hw = iwl_alloc_all(cfg, &iwl3945_hw_ops); 3969 hw = iwl_alloc_all(cfg);
3970 if (hw == NULL) { 3970 if (hw == NULL) {
3971 pr_err("Can not allocate network device\n"); 3971 pr_err("Can not allocate network device\n");
3972 err = -ENOMEM; 3972 err = -ENOMEM;