diff options
author | David Woodhouse <David.Woodhouse@intel.com> | 2008-09-01 06:32:13 -0400 |
---|---|---|
committer | David Woodhouse <David.Woodhouse@intel.com> | 2008-09-01 06:32:13 -0400 |
commit | 9d7548d4ca3c52ecb58f098a32b0756cdf8f96ee (patch) | |
tree | 651f7058bbaa2d8b2855286380d614afcf505118 /drivers/net/wireless | |
parent | 31db6e9ea1dbdcf66b8227b4f7035dee1b1dd8c0 (diff) | |
parent | bef69ea0dcce574a425feb0a5aa4c63dd108b9a6 (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'drivers/net/wireless')
28 files changed, 121 insertions, 98 deletions
diff --git a/drivers/net/wireless/ath5k/base.c b/drivers/net/wireless/ath5k/base.c index 2028866f5995..0676c6d84383 100644 --- a/drivers/net/wireless/ath5k/base.c +++ b/drivers/net/wireless/ath5k/base.c | |||
@@ -40,7 +40,6 @@ | |||
40 | * | 40 | * |
41 | */ | 41 | */ |
42 | 42 | ||
43 | #include <linux/version.h> | ||
44 | #include <linux/module.h> | 43 | #include <linux/module.h> |
45 | #include <linux/delay.h> | 44 | #include <linux/delay.h> |
46 | #include <linux/hardirq.h> | 45 | #include <linux/hardirq.h> |
@@ -252,7 +251,7 @@ static inline void ath5k_txbuf_free(struct ath5k_softc *sc, | |||
252 | return; | 251 | return; |
253 | pci_unmap_single(sc->pdev, bf->skbaddr, bf->skb->len, | 252 | pci_unmap_single(sc->pdev, bf->skbaddr, bf->skb->len, |
254 | PCI_DMA_TODEVICE); | 253 | PCI_DMA_TODEVICE); |
255 | dev_kfree_skb(bf->skb); | 254 | dev_kfree_skb_any(bf->skb); |
256 | bf->skb = NULL; | 255 | bf->skb = NULL; |
257 | } | 256 | } |
258 | 257 | ||
@@ -467,6 +466,7 @@ ath5k_pci_probe(struct pci_dev *pdev, | |||
467 | mutex_init(&sc->lock); | 466 | mutex_init(&sc->lock); |
468 | spin_lock_init(&sc->rxbuflock); | 467 | spin_lock_init(&sc->rxbuflock); |
469 | spin_lock_init(&sc->txbuflock); | 468 | spin_lock_init(&sc->txbuflock); |
469 | spin_lock_init(&sc->block); | ||
470 | 470 | ||
471 | /* Set private data */ | 471 | /* Set private data */ |
472 | pci_set_drvdata(pdev, hw); | 472 | pci_set_drvdata(pdev, hw); |
@@ -587,7 +587,6 @@ ath5k_pci_suspend(struct pci_dev *pdev, pm_message_t state) | |||
587 | ath5k_stop_hw(sc); | 587 | ath5k_stop_hw(sc); |
588 | 588 | ||
589 | free_irq(pdev->irq, sc); | 589 | free_irq(pdev->irq, sc); |
590 | pci_disable_msi(pdev); | ||
591 | pci_save_state(pdev); | 590 | pci_save_state(pdev); |
592 | pci_disable_device(pdev); | 591 | pci_disable_device(pdev); |
593 | pci_set_power_state(pdev, PCI_D3hot); | 592 | pci_set_power_state(pdev, PCI_D3hot); |
@@ -616,12 +615,10 @@ ath5k_pci_resume(struct pci_dev *pdev) | |||
616 | */ | 615 | */ |
617 | pci_write_config_byte(pdev, 0x41, 0); | 616 | pci_write_config_byte(pdev, 0x41, 0); |
618 | 617 | ||
619 | pci_enable_msi(pdev); | ||
620 | |||
621 | err = request_irq(pdev->irq, ath5k_intr, IRQF_SHARED, "ath", sc); | 618 | err = request_irq(pdev->irq, ath5k_intr, IRQF_SHARED, "ath", sc); |
622 | if (err) { | 619 | if (err) { |
623 | ATH5K_ERR(sc, "request_irq failed\n"); | 620 | ATH5K_ERR(sc, "request_irq failed\n"); |
624 | goto err_msi; | 621 | goto err_no_irq; |
625 | } | 622 | } |
626 | 623 | ||
627 | err = ath5k_init(sc); | 624 | err = ath5k_init(sc); |
@@ -642,8 +639,7 @@ ath5k_pci_resume(struct pci_dev *pdev) | |||
642 | return 0; | 639 | return 0; |
643 | err_irq: | 640 | err_irq: |
644 | free_irq(pdev->irq, sc); | 641 | free_irq(pdev->irq, sc); |
645 | err_msi: | 642 | err_no_irq: |
646 | pci_disable_msi(pdev); | ||
647 | pci_disable_device(pdev); | 643 | pci_disable_device(pdev); |
648 | return err; | 644 | return err; |
649 | } | 645 | } |
@@ -2184,8 +2180,11 @@ ath5k_beacon_config(struct ath5k_softc *sc) | |||
2184 | 2180 | ||
2185 | sc->imask |= AR5K_INT_SWBA; | 2181 | sc->imask |= AR5K_INT_SWBA; |
2186 | 2182 | ||
2187 | if (ath5k_hw_hasveol(ah)) | 2183 | if (ath5k_hw_hasveol(ah)) { |
2184 | spin_lock(&sc->block); | ||
2188 | ath5k_beacon_send(sc); | 2185 | ath5k_beacon_send(sc); |
2186 | spin_unlock(&sc->block); | ||
2187 | } | ||
2189 | } | 2188 | } |
2190 | /* TODO else AP */ | 2189 | /* TODO else AP */ |
2191 | 2190 | ||
@@ -2408,7 +2407,9 @@ ath5k_intr(int irq, void *dev_id) | |||
2408 | TSF_TO_TU(tsf), | 2407 | TSF_TO_TU(tsf), |
2409 | (unsigned long long) tsf); | 2408 | (unsigned long long) tsf); |
2410 | } else { | 2409 | } else { |
2410 | spin_lock(&sc->block); | ||
2411 | ath5k_beacon_send(sc); | 2411 | ath5k_beacon_send(sc); |
2412 | spin_unlock(&sc->block); | ||
2412 | } | 2413 | } |
2413 | } | 2414 | } |
2414 | if (status & AR5K_INT_RXEOL) { | 2415 | if (status & AR5K_INT_RXEOL) { |
@@ -2750,6 +2751,11 @@ static int ath5k_add_interface(struct ieee80211_hw *hw, | |||
2750 | ret = -EOPNOTSUPP; | 2751 | ret = -EOPNOTSUPP; |
2751 | goto end; | 2752 | goto end; |
2752 | } | 2753 | } |
2754 | |||
2755 | /* Set to a reasonable value. Note that this will | ||
2756 | * be set to mac80211's value at ath5k_config(). */ | ||
2757 | sc->bintval = 1000; | ||
2758 | |||
2753 | ret = 0; | 2759 | ret = 0; |
2754 | end: | 2760 | end: |
2755 | mutex_unlock(&sc->lock); | 2761 | mutex_unlock(&sc->lock); |
@@ -2794,9 +2800,6 @@ ath5k_config_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif, | |||
2794 | struct ath5k_hw *ah = sc->ah; | 2800 | struct ath5k_hw *ah = sc->ah; |
2795 | int ret; | 2801 | int ret; |
2796 | 2802 | ||
2797 | /* Set to a reasonable value. Note that this will | ||
2798 | * be set to mac80211's value at ath5k_config(). */ | ||
2799 | sc->bintval = 1000; | ||
2800 | mutex_lock(&sc->lock); | 2803 | mutex_lock(&sc->lock); |
2801 | if (sc->vif != vif) { | 2804 | if (sc->vif != vif) { |
2802 | ret = -EIO; | 2805 | ret = -EIO; |
@@ -3055,6 +3058,7 @@ static int | |||
3055 | ath5k_beacon_update(struct ieee80211_hw *hw, struct sk_buff *skb) | 3058 | ath5k_beacon_update(struct ieee80211_hw *hw, struct sk_buff *skb) |
3056 | { | 3059 | { |
3057 | struct ath5k_softc *sc = hw->priv; | 3060 | struct ath5k_softc *sc = hw->priv; |
3061 | unsigned long flags; | ||
3058 | int ret; | 3062 | int ret; |
3059 | 3063 | ||
3060 | ath5k_debug_dump_skb(sc, skb, "BC ", 1); | 3064 | ath5k_debug_dump_skb(sc, skb, "BC ", 1); |
@@ -3064,12 +3068,14 @@ ath5k_beacon_update(struct ieee80211_hw *hw, struct sk_buff *skb) | |||
3064 | goto end; | 3068 | goto end; |
3065 | } | 3069 | } |
3066 | 3070 | ||
3071 | spin_lock_irqsave(&sc->block, flags); | ||
3067 | ath5k_txbuf_free(sc, sc->bbuf); | 3072 | ath5k_txbuf_free(sc, sc->bbuf); |
3068 | sc->bbuf->skb = skb; | 3073 | sc->bbuf->skb = skb; |
3069 | ret = ath5k_beacon_setup(sc, sc->bbuf); | 3074 | ret = ath5k_beacon_setup(sc, sc->bbuf); |
3070 | if (ret) | 3075 | if (ret) |
3071 | sc->bbuf->skb = NULL; | 3076 | sc->bbuf->skb = NULL; |
3072 | else { | 3077 | spin_unlock_irqrestore(&sc->block, flags); |
3078 | if (!ret) { | ||
3073 | ath5k_beacon_config(sc); | 3079 | ath5k_beacon_config(sc); |
3074 | mmiowb(); | 3080 | mmiowb(); |
3075 | } | 3081 | } |
diff --git a/drivers/net/wireless/ath5k/base.h b/drivers/net/wireless/ath5k/base.h index d7e03e6b8271..7ec2f377d5c7 100644 --- a/drivers/net/wireless/ath5k/base.h +++ b/drivers/net/wireless/ath5k/base.h | |||
@@ -172,6 +172,7 @@ struct ath5k_softc { | |||
172 | struct tasklet_struct txtq; /* tx intr tasklet */ | 172 | struct tasklet_struct txtq; /* tx intr tasklet */ |
173 | struct ath5k_led tx_led; /* tx led */ | 173 | struct ath5k_led tx_led; /* tx led */ |
174 | 174 | ||
175 | spinlock_t block; /* protects beacon */ | ||
175 | struct ath5k_buf *bbuf; /* beacon buffer */ | 176 | struct ath5k_buf *bbuf; /* beacon buffer */ |
176 | unsigned int bhalq, /* SW q for outgoing beacons */ | 177 | unsigned int bhalq, /* SW q for outgoing beacons */ |
177 | bmisscount, /* missed beacon transmits */ | 178 | bmisscount, /* missed beacon transmits */ |
diff --git a/drivers/net/wireless/ath9k/hw.c b/drivers/net/wireless/ath9k/hw.c index bde162f128ab..a17eb130f574 100644 --- a/drivers/net/wireless/ath9k/hw.c +++ b/drivers/net/wireless/ath9k/hw.c | |||
@@ -5017,7 +5017,11 @@ static void ath9k_hw_spur_mitigate(struct ath_hal *ah, | |||
5017 | 5017 | ||
5018 | for (i = 0; i < 123; i++) { | 5018 | for (i = 0; i < 123; i++) { |
5019 | if ((cur_vit_mask > lower) && (cur_vit_mask < upper)) { | 5019 | if ((cur_vit_mask > lower) && (cur_vit_mask < upper)) { |
5020 | if ((abs(cur_vit_mask - bin)) < 75) | 5020 | |
5021 | /* workaround for gcc bug #37014 */ | ||
5022 | volatile int tmp = abs(cur_vit_mask - bin); | ||
5023 | |||
5024 | if (tmp < 75) | ||
5021 | mask_amt = 1; | 5025 | mask_amt = 1; |
5022 | else | 5026 | else |
5023 | mask_amt = 0; | 5027 | mask_amt = 0; |
diff --git a/drivers/net/wireless/atmel.c b/drivers/net/wireless/atmel.c index bd35bb0a1480..bd65c485098c 100644 --- a/drivers/net/wireless/atmel.c +++ b/drivers/net/wireless/atmel.c | |||
@@ -1304,7 +1304,7 @@ EXPORT_SYMBOL(atmel_open); | |||
1304 | int atmel_open(struct net_device *dev) | 1304 | int atmel_open(struct net_device *dev) |
1305 | { | 1305 | { |
1306 | struct atmel_private *priv = netdev_priv(dev); | 1306 | struct atmel_private *priv = netdev_priv(dev); |
1307 | int i, channel; | 1307 | int i, channel, err; |
1308 | 1308 | ||
1309 | /* any scheduled timer is no longer needed and might screw things up.. */ | 1309 | /* any scheduled timer is no longer needed and might screw things up.. */ |
1310 | del_timer_sync(&priv->management_timer); | 1310 | del_timer_sync(&priv->management_timer); |
@@ -1328,8 +1328,9 @@ int atmel_open(struct net_device *dev) | |||
1328 | priv->site_survey_state = SITE_SURVEY_IDLE; | 1328 | priv->site_survey_state = SITE_SURVEY_IDLE; |
1329 | priv->station_is_associated = 0; | 1329 | priv->station_is_associated = 0; |
1330 | 1330 | ||
1331 | if (!reset_atmel_card(dev)) | 1331 | err = reset_atmel_card(dev); |
1332 | return -EAGAIN; | 1332 | if (err) |
1333 | return err; | ||
1333 | 1334 | ||
1334 | if (priv->config_reg_domain) { | 1335 | if (priv->config_reg_domain) { |
1335 | priv->reg_domain = priv->config_reg_domain; | 1336 | priv->reg_domain = priv->config_reg_domain; |
@@ -3061,12 +3062,20 @@ static void authenticate(struct atmel_private *priv, u16 frame_len) | |||
3061 | } | 3062 | } |
3062 | 3063 | ||
3063 | if (status == WLAN_STATUS_NOT_SUPPORTED_AUTH_ALG) { | 3064 | if (status == WLAN_STATUS_NOT_SUPPORTED_AUTH_ALG) { |
3064 | /* Do opensystem first, then try sharedkey */ | 3065 | /* Flip back and forth between WEP auth modes until the max |
3066 | * authentication tries has been exceeded. | ||
3067 | */ | ||
3065 | if (system == WLAN_AUTH_OPEN) { | 3068 | if (system == WLAN_AUTH_OPEN) { |
3066 | priv->CurrentAuthentTransactionSeqNum = 0x001; | 3069 | priv->CurrentAuthentTransactionSeqNum = 0x001; |
3067 | priv->exclude_unencrypted = 1; | 3070 | priv->exclude_unencrypted = 1; |
3068 | send_authentication_request(priv, WLAN_AUTH_SHARED_KEY, NULL, 0); | 3071 | send_authentication_request(priv, WLAN_AUTH_SHARED_KEY, NULL, 0); |
3069 | return; | 3072 | return; |
3073 | } else if ( system == WLAN_AUTH_SHARED_KEY | ||
3074 | && priv->wep_is_on) { | ||
3075 | priv->CurrentAuthentTransactionSeqNum = 0x001; | ||
3076 | priv->exclude_unencrypted = 0; | ||
3077 | send_authentication_request(priv, WLAN_AUTH_OPEN, NULL, 0); | ||
3078 | return; | ||
3070 | } else if (priv->connect_to_any_BSS) { | 3079 | } else if (priv->connect_to_any_BSS) { |
3071 | int bss_index; | 3080 | int bss_index; |
3072 | 3081 | ||
@@ -3580,12 +3589,12 @@ static int atmel_wakeup_firmware(struct atmel_private *priv) | |||
3580 | 3589 | ||
3581 | if (i == 0) { | 3590 | if (i == 0) { |
3582 | printk(KERN_ALERT "%s: MAC failed to boot.\n", priv->dev->name); | 3591 | printk(KERN_ALERT "%s: MAC failed to boot.\n", priv->dev->name); |
3583 | return 0; | 3592 | return -EIO; |
3584 | } | 3593 | } |
3585 | 3594 | ||
3586 | if ((priv->host_info_base = atmel_read16(priv->dev, MR2)) == 0xffff) { | 3595 | if ((priv->host_info_base = atmel_read16(priv->dev, MR2)) == 0xffff) { |
3587 | printk(KERN_ALERT "%s: card missing.\n", priv->dev->name); | 3596 | printk(KERN_ALERT "%s: card missing.\n", priv->dev->name); |
3588 | return 0; | 3597 | return -ENODEV; |
3589 | } | 3598 | } |
3590 | 3599 | ||
3591 | /* now check for completion of MAC initialization through | 3600 | /* now check for completion of MAC initialization through |
@@ -3609,19 +3618,19 @@ static int atmel_wakeup_firmware(struct atmel_private *priv) | |||
3609 | if (i == 0) { | 3618 | if (i == 0) { |
3610 | printk(KERN_ALERT "%s: MAC failed to initialise.\n", | 3619 | printk(KERN_ALERT "%s: MAC failed to initialise.\n", |
3611 | priv->dev->name); | 3620 | priv->dev->name); |
3612 | return 0; | 3621 | return -EIO; |
3613 | } | 3622 | } |
3614 | 3623 | ||
3615 | /* Check for MAC_INIT_OK only on the register that the MAC_INIT_OK was set */ | 3624 | /* Check for MAC_INIT_OK only on the register that the MAC_INIT_OK was set */ |
3616 | if ((mr3 & MAC_INIT_COMPLETE) && | 3625 | if ((mr3 & MAC_INIT_COMPLETE) && |
3617 | !(atmel_read16(priv->dev, MR3) & MAC_INIT_OK)) { | 3626 | !(atmel_read16(priv->dev, MR3) & MAC_INIT_OK)) { |
3618 | printk(KERN_ALERT "%s: MAC failed MR3 self-test.\n", priv->dev->name); | 3627 | printk(KERN_ALERT "%s: MAC failed MR3 self-test.\n", priv->dev->name); |
3619 | return 0; | 3628 | return -EIO; |
3620 | } | 3629 | } |
3621 | if ((mr1 & MAC_INIT_COMPLETE) && | 3630 | if ((mr1 & MAC_INIT_COMPLETE) && |
3622 | !(atmel_read16(priv->dev, MR1) & MAC_INIT_OK)) { | 3631 | !(atmel_read16(priv->dev, MR1) & MAC_INIT_OK)) { |
3623 | printk(KERN_ALERT "%s: MAC failed MR1 self-test.\n", priv->dev->name); | 3632 | printk(KERN_ALERT "%s: MAC failed MR1 self-test.\n", priv->dev->name); |
3624 | return 0; | 3633 | return -EIO; |
3625 | } | 3634 | } |
3626 | 3635 | ||
3627 | atmel_copy_to_host(priv->dev, (unsigned char *)iface, | 3636 | atmel_copy_to_host(priv->dev, (unsigned char *)iface, |
@@ -3642,7 +3651,7 @@ static int atmel_wakeup_firmware(struct atmel_private *priv) | |||
3642 | iface->func_ctrl = le16_to_cpu(iface->func_ctrl); | 3651 | iface->func_ctrl = le16_to_cpu(iface->func_ctrl); |
3643 | iface->mac_status = le16_to_cpu(iface->mac_status); | 3652 | iface->mac_status = le16_to_cpu(iface->mac_status); |
3644 | 3653 | ||
3645 | return 1; | 3654 | return 0; |
3646 | } | 3655 | } |
3647 | 3656 | ||
3648 | /* determine type of memory and MAC address */ | 3657 | /* determine type of memory and MAC address */ |
@@ -3693,7 +3702,7 @@ static int probe_atmel_card(struct net_device *dev) | |||
3693 | /* Standard firmware in flash, boot it up and ask | 3702 | /* Standard firmware in flash, boot it up and ask |
3694 | for the Mac Address */ | 3703 | for the Mac Address */ |
3695 | priv->card_type = CARD_TYPE_SPI_FLASH; | 3704 | priv->card_type = CARD_TYPE_SPI_FLASH; |
3696 | if (atmel_wakeup_firmware(priv)) { | 3705 | if (atmel_wakeup_firmware(priv) == 0) { |
3697 | atmel_get_mib(priv, Mac_Address_Mib_Type, 0, dev->dev_addr, 6); | 3706 | atmel_get_mib(priv, Mac_Address_Mib_Type, 0, dev->dev_addr, 6); |
3698 | 3707 | ||
3699 | /* got address, now squash it again until the network | 3708 | /* got address, now squash it again until the network |
@@ -3835,6 +3844,7 @@ static int reset_atmel_card(struct net_device *dev) | |||
3835 | struct atmel_private *priv = netdev_priv(dev); | 3844 | struct atmel_private *priv = netdev_priv(dev); |
3836 | u8 configuration; | 3845 | u8 configuration; |
3837 | int old_state = priv->station_state; | 3846 | int old_state = priv->station_state; |
3847 | int err = 0; | ||
3838 | 3848 | ||
3839 | /* data to add to the firmware names, in priority order | 3849 | /* data to add to the firmware names, in priority order |
3840 | this implemenents firmware versioning */ | 3850 | this implemenents firmware versioning */ |
@@ -3868,11 +3878,12 @@ static int reset_atmel_card(struct net_device *dev) | |||
3868 | dev->name); | 3878 | dev->name); |
3869 | strcpy(priv->firmware_id, "atmel_at76c502.bin"); | 3879 | strcpy(priv->firmware_id, "atmel_at76c502.bin"); |
3870 | } | 3880 | } |
3871 | if (request_firmware(&fw_entry, priv->firmware_id, priv->sys_dev) != 0) { | 3881 | err = request_firmware(&fw_entry, priv->firmware_id, priv->sys_dev); |
3882 | if (err != 0) { | ||
3872 | printk(KERN_ALERT | 3883 | printk(KERN_ALERT |
3873 | "%s: firmware %s is missing, cannot continue.\n", | 3884 | "%s: firmware %s is missing, cannot continue.\n", |
3874 | dev->name, priv->firmware_id); | 3885 | dev->name, priv->firmware_id); |
3875 | return 0; | 3886 | return err; |
3876 | } | 3887 | } |
3877 | } else { | 3888 | } else { |
3878 | int fw_index = 0; | 3889 | int fw_index = 0; |
@@ -3901,7 +3912,7 @@ static int reset_atmel_card(struct net_device *dev) | |||
3901 | "%s: firmware %s is missing, cannot start.\n", | 3912 | "%s: firmware %s is missing, cannot start.\n", |
3902 | dev->name, priv->firmware_id); | 3913 | dev->name, priv->firmware_id); |
3903 | priv->firmware_id[0] = '\0'; | 3914 | priv->firmware_id[0] = '\0'; |
3904 | return 0; | 3915 | return -ENOENT; |
3905 | } | 3916 | } |
3906 | } | 3917 | } |
3907 | 3918 | ||
@@ -3926,8 +3937,9 @@ static int reset_atmel_card(struct net_device *dev) | |||
3926 | release_firmware(fw_entry); | 3937 | release_firmware(fw_entry); |
3927 | } | 3938 | } |
3928 | 3939 | ||
3929 | if (!atmel_wakeup_firmware(priv)) | 3940 | err = atmel_wakeup_firmware(priv); |
3930 | return 0; | 3941 | if (err != 0) |
3942 | return err; | ||
3931 | 3943 | ||
3932 | /* Check the version and set the correct flag for wpa stuff, | 3944 | /* Check the version and set the correct flag for wpa stuff, |
3933 | old and new firmware is incompatible. | 3945 | old and new firmware is incompatible. |
@@ -3968,10 +3980,9 @@ static int reset_atmel_card(struct net_device *dev) | |||
3968 | if (!priv->radio_on_broken) { | 3980 | if (!priv->radio_on_broken) { |
3969 | if (atmel_send_command_wait(priv, CMD_EnableRadio, NULL, 0) == | 3981 | if (atmel_send_command_wait(priv, CMD_EnableRadio, NULL, 0) == |
3970 | CMD_STATUS_REJECTED_RADIO_OFF) { | 3982 | CMD_STATUS_REJECTED_RADIO_OFF) { |
3971 | printk(KERN_INFO | 3983 | printk(KERN_INFO "%s: cannot turn the radio on.\n", |
3972 | "%s: cannot turn the radio on. (Hey radio, you're beautiful!)\n", | ||
3973 | dev->name); | 3984 | dev->name); |
3974 | return 0; | 3985 | return -EIO; |
3975 | } | 3986 | } |
3976 | } | 3987 | } |
3977 | 3988 | ||
@@ -4006,7 +4017,7 @@ static int reset_atmel_card(struct net_device *dev) | |||
4006 | wireless_send_event(priv->dev, SIOCGIWAP, &wrqu, NULL); | 4017 | wireless_send_event(priv->dev, SIOCGIWAP, &wrqu, NULL); |
4007 | } | 4018 | } |
4008 | 4019 | ||
4009 | return 1; | 4020 | return 0; |
4010 | } | 4021 | } |
4011 | 4022 | ||
4012 | static void atmel_send_command(struct atmel_private *priv, int command, | 4023 | static void atmel_send_command(struct atmel_private *priv, int command, |
diff --git a/drivers/net/wireless/b43/main.c b/drivers/net/wireless/b43/main.c index 3bf3a869361f..7205a936ec74 100644 --- a/drivers/net/wireless/b43/main.c +++ b/drivers/net/wireless/b43/main.c | |||
@@ -33,7 +33,6 @@ | |||
33 | #include <linux/moduleparam.h> | 33 | #include <linux/moduleparam.h> |
34 | #include <linux/if_arp.h> | 34 | #include <linux/if_arp.h> |
35 | #include <linux/etherdevice.h> | 35 | #include <linux/etherdevice.h> |
36 | #include <linux/version.h> | ||
37 | #include <linux/firmware.h> | 36 | #include <linux/firmware.h> |
38 | #include <linux/wireless.h> | 37 | #include <linux/wireless.h> |
39 | #include <linux/workqueue.h> | 38 | #include <linux/workqueue.h> |
@@ -4615,7 +4614,9 @@ static void b43_sprom_fixup(struct ssb_bus *bus) | |||
4615 | if (bus->bustype == SSB_BUSTYPE_PCI) { | 4614 | if (bus->bustype == SSB_BUSTYPE_PCI) { |
4616 | pdev = bus->host_pci; | 4615 | pdev = bus->host_pci; |
4617 | if (IS_PDEV(pdev, BROADCOM, 0x4318, ASUSTEK, 0x100F) || | 4616 | if (IS_PDEV(pdev, BROADCOM, 0x4318, ASUSTEK, 0x100F) || |
4617 | IS_PDEV(pdev, BROADCOM, 0x4320, DELL, 0x0003) || | ||
4618 | IS_PDEV(pdev, BROADCOM, 0x4320, LINKSYS, 0x0015) || | 4618 | IS_PDEV(pdev, BROADCOM, 0x4320, LINKSYS, 0x0015) || |
4619 | IS_PDEV(pdev, BROADCOM, 0x4320, LINKSYS, 0x0014) || | ||
4619 | IS_PDEV(pdev, BROADCOM, 0x4320, LINKSYS, 0x0013)) | 4620 | IS_PDEV(pdev, BROADCOM, 0x4320, LINKSYS, 0x0013)) |
4620 | bus->sprom.boardflags_lo &= ~B43_BFL_BTCOEXIST; | 4621 | bus->sprom.boardflags_lo &= ~B43_BFL_BTCOEXIST; |
4621 | } | 4622 | } |
diff --git a/drivers/net/wireless/b43legacy/main.c b/drivers/net/wireless/b43legacy/main.c index 2541c81932f0..1cb77db5c292 100644 --- a/drivers/net/wireless/b43legacy/main.c +++ b/drivers/net/wireless/b43legacy/main.c | |||
@@ -34,7 +34,6 @@ | |||
34 | #include <linux/moduleparam.h> | 34 | #include <linux/moduleparam.h> |
35 | #include <linux/if_arp.h> | 35 | #include <linux/if_arp.h> |
36 | #include <linux/etherdevice.h> | 36 | #include <linux/etherdevice.h> |
37 | #include <linux/version.h> | ||
38 | #include <linux/firmware.h> | 37 | #include <linux/firmware.h> |
39 | #include <linux/wireless.h> | 38 | #include <linux/wireless.h> |
40 | #include <linux/workqueue.h> | 39 | #include <linux/workqueue.h> |
diff --git a/drivers/net/wireless/ipw2100.c b/drivers/net/wireless/ipw2100.c index c6f886ec08a3..19a401c4a0dc 100644 --- a/drivers/net/wireless/ipw2100.c +++ b/drivers/net/wireless/ipw2100.c | |||
@@ -157,7 +157,6 @@ that only one external action is invoked at a time. | |||
157 | #include <linux/stringify.h> | 157 | #include <linux/stringify.h> |
158 | #include <linux/tcp.h> | 158 | #include <linux/tcp.h> |
159 | #include <linux/types.h> | 159 | #include <linux/types.h> |
160 | #include <linux/version.h> | ||
161 | #include <linux/time.h> | 160 | #include <linux/time.h> |
162 | #include <linux/firmware.h> | 161 | #include <linux/firmware.h> |
163 | #include <linux/acpi.h> | 162 | #include <linux/acpi.h> |
diff --git a/drivers/net/wireless/ipw2200.c b/drivers/net/wireless/ipw2200.c index 36e8d2f6e7b4..dcce3542d5a7 100644 --- a/drivers/net/wireless/ipw2200.c +++ b/drivers/net/wireless/ipw2200.c | |||
@@ -31,7 +31,6 @@ | |||
31 | ******************************************************************************/ | 31 | ******************************************************************************/ |
32 | 32 | ||
33 | #include "ipw2200.h" | 33 | #include "ipw2200.h" |
34 | #include <linux/version.h> | ||
35 | 34 | ||
36 | 35 | ||
37 | #ifndef KBUILD_EXTMOD | 36 | #ifndef KBUILD_EXTMOD |
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945-led.c b/drivers/net/wireless/iwlwifi/iwl-3945-led.c index d3336966b6b5..705c65bed9fd 100644 --- a/drivers/net/wireless/iwlwifi/iwl-3945-led.c +++ b/drivers/net/wireless/iwlwifi/iwl-3945-led.c | |||
@@ -27,7 +27,6 @@ | |||
27 | 27 | ||
28 | #include <linux/kernel.h> | 28 | #include <linux/kernel.h> |
29 | #include <linux/module.h> | 29 | #include <linux/module.h> |
30 | #include <linux/version.h> | ||
31 | #include <linux/init.h> | 30 | #include <linux/init.h> |
32 | #include <linux/pci.h> | 31 | #include <linux/pci.h> |
33 | #include <linux/dma-mapping.h> | 32 | #include <linux/dma-mapping.h> |
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.c b/drivers/net/wireless/iwlwifi/iwl-3945.c index b3931f6135a4..3f51f3635344 100644 --- a/drivers/net/wireless/iwlwifi/iwl-3945.c +++ b/drivers/net/wireless/iwlwifi/iwl-3945.c | |||
@@ -26,7 +26,6 @@ | |||
26 | 26 | ||
27 | #include <linux/kernel.h> | 27 | #include <linux/kernel.h> |
28 | #include <linux/module.h> | 28 | #include <linux/module.h> |
29 | #include <linux/version.h> | ||
30 | #include <linux/init.h> | 29 | #include <linux/init.h> |
31 | #include <linux/pci.h> | 30 | #include <linux/pci.h> |
32 | #include <linux/dma-mapping.h> | 31 | #include <linux/dma-mapping.h> |
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965.c b/drivers/net/wireless/iwlwifi/iwl-4965.c index 22bb26985c2e..e2581229d8b2 100644 --- a/drivers/net/wireless/iwlwifi/iwl-4965.c +++ b/drivers/net/wireless/iwlwifi/iwl-4965.c | |||
@@ -26,7 +26,6 @@ | |||
26 | 26 | ||
27 | #include <linux/kernel.h> | 27 | #include <linux/kernel.h> |
28 | #include <linux/module.h> | 28 | #include <linux/module.h> |
29 | #include <linux/version.h> | ||
30 | #include <linux/init.h> | 29 | #include <linux/init.h> |
31 | #include <linux/pci.h> | 30 | #include <linux/pci.h> |
32 | #include <linux/dma-mapping.h> | 31 | #include <linux/dma-mapping.h> |
@@ -967,7 +966,7 @@ static int iwl4965_interpolate_chan(struct iwl_priv *priv, u32 channel, | |||
967 | 966 | ||
968 | s = iwl4965_get_sub_band(priv, channel); | 967 | s = iwl4965_get_sub_band(priv, channel); |
969 | if (s >= EEPROM_TX_POWER_BANDS) { | 968 | if (s >= EEPROM_TX_POWER_BANDS) { |
970 | IWL_ERROR("Tx Power can not find channel %d ", channel); | 969 | IWL_ERROR("Tx Power can not find channel %d\n", channel); |
971 | return -1; | 970 | return -1; |
972 | } | 971 | } |
973 | 972 | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl-5000.c b/drivers/net/wireless/iwlwifi/iwl-5000.c index f3d139b663e6..cbc01a00eaf4 100644 --- a/drivers/net/wireless/iwlwifi/iwl-5000.c +++ b/drivers/net/wireless/iwlwifi/iwl-5000.c | |||
@@ -25,7 +25,6 @@ | |||
25 | 25 | ||
26 | #include <linux/kernel.h> | 26 | #include <linux/kernel.h> |
27 | #include <linux/module.h> | 27 | #include <linux/module.h> |
28 | #include <linux/version.h> | ||
29 | #include <linux/init.h> | 28 | #include <linux/init.h> |
30 | #include <linux/pci.h> | 29 | #include <linux/pci.h> |
31 | #include <linux/dma-mapping.h> | 30 | #include <linux/dma-mapping.h> |
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c index ed09e48b1b61..061ffba9c884 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn.c | |||
@@ -29,7 +29,6 @@ | |||
29 | 29 | ||
30 | #include <linux/kernel.h> | 30 | #include <linux/kernel.h> |
31 | #include <linux/module.h> | 31 | #include <linux/module.h> |
32 | #include <linux/version.h> | ||
33 | #include <linux/init.h> | 32 | #include <linux/init.h> |
34 | #include <linux/pci.h> | 33 | #include <linux/pci.h> |
35 | #include <linux/dma-mapping.h> | 34 | #include <linux/dma-mapping.h> |
diff --git a/drivers/net/wireless/iwlwifi/iwl-core.c b/drivers/net/wireless/iwlwifi/iwl-core.c index 9bd61809129f..c72f72579bea 100644 --- a/drivers/net/wireless/iwlwifi/iwl-core.c +++ b/drivers/net/wireless/iwlwifi/iwl-core.c | |||
@@ -28,7 +28,6 @@ | |||
28 | 28 | ||
29 | #include <linux/kernel.h> | 29 | #include <linux/kernel.h> |
30 | #include <linux/module.h> | 30 | #include <linux/module.h> |
31 | #include <linux/version.h> | ||
32 | #include <net/mac80211.h> | 31 | #include <net/mac80211.h> |
33 | 32 | ||
34 | struct iwl_priv; /* FIXME: remove */ | 33 | struct iwl_priv; /* FIXME: remove */ |
diff --git a/drivers/net/wireless/iwlwifi/iwl-eeprom.c b/drivers/net/wireless/iwlwifi/iwl-eeprom.c index bce53830b301..37155755efc5 100644 --- a/drivers/net/wireless/iwlwifi/iwl-eeprom.c +++ b/drivers/net/wireless/iwlwifi/iwl-eeprom.c | |||
@@ -63,7 +63,6 @@ | |||
63 | 63 | ||
64 | #include <linux/kernel.h> | 64 | #include <linux/kernel.h> |
65 | #include <linux/module.h> | 65 | #include <linux/module.h> |
66 | #include <linux/version.h> | ||
67 | #include <linux/init.h> | 66 | #include <linux/init.h> |
68 | 67 | ||
69 | #include <net/mac80211.h> | 68 | #include <net/mac80211.h> |
@@ -146,7 +145,7 @@ int iwlcore_eeprom_verify_signature(struct iwl_priv *priv) | |||
146 | { | 145 | { |
147 | u32 gp = iwl_read32(priv, CSR_EEPROM_GP); | 146 | u32 gp = iwl_read32(priv, CSR_EEPROM_GP); |
148 | if ((gp & CSR_EEPROM_GP_VALID_MSK) == CSR_EEPROM_GP_BAD_SIGNATURE) { | 147 | if ((gp & CSR_EEPROM_GP_VALID_MSK) == CSR_EEPROM_GP_BAD_SIGNATURE) { |
149 | IWL_ERROR("EEPROM not found, EEPROM_GP=0x%08x", gp); | 148 | IWL_ERROR("EEPROM not found, EEPROM_GP=0x%08x\n", gp); |
150 | return -ENOENT; | 149 | return -ENOENT; |
151 | } | 150 | } |
152 | return 0; | 151 | return 0; |
@@ -227,7 +226,7 @@ int iwl_eeprom_init(struct iwl_priv *priv) | |||
227 | 226 | ||
228 | ret = priv->cfg->ops->lib->eeprom_ops.verify_signature(priv); | 227 | ret = priv->cfg->ops->lib->eeprom_ops.verify_signature(priv); |
229 | if (ret < 0) { | 228 | if (ret < 0) { |
230 | IWL_ERROR("EEPROM not found, EEPROM_GP=0x%08x", gp); | 229 | IWL_ERROR("EEPROM not found, EEPROM_GP=0x%08x\n", gp); |
231 | ret = -ENOENT; | 230 | ret = -ENOENT; |
232 | goto err; | 231 | goto err; |
233 | } | 232 | } |
@@ -254,7 +253,7 @@ int iwl_eeprom_init(struct iwl_priv *priv) | |||
254 | } | 253 | } |
255 | 254 | ||
256 | if (!(r & CSR_EEPROM_REG_READ_VALID_MSK)) { | 255 | if (!(r & CSR_EEPROM_REG_READ_VALID_MSK)) { |
257 | IWL_ERROR("Time out reading EEPROM[%d]", addr); | 256 | IWL_ERROR("Time out reading EEPROM[%d]\n", addr); |
258 | ret = -ETIMEDOUT; | 257 | ret = -ETIMEDOUT; |
259 | goto done; | 258 | goto done; |
260 | } | 259 | } |
diff --git a/drivers/net/wireless/iwlwifi/iwl-hcmd.c b/drivers/net/wireless/iwlwifi/iwl-hcmd.c index 6512834bb916..2eb03eea1908 100644 --- a/drivers/net/wireless/iwlwifi/iwl-hcmd.c +++ b/drivers/net/wireless/iwlwifi/iwl-hcmd.c | |||
@@ -28,7 +28,6 @@ | |||
28 | 28 | ||
29 | #include <linux/kernel.h> | 29 | #include <linux/kernel.h> |
30 | #include <linux/module.h> | 30 | #include <linux/module.h> |
31 | #include <linux/version.h> | ||
32 | #include <net/mac80211.h> | 31 | #include <net/mac80211.h> |
33 | 32 | ||
34 | #include "iwl-dev.h" /* FIXME: remove */ | 33 | #include "iwl-dev.h" /* FIXME: remove */ |
diff --git a/drivers/net/wireless/iwlwifi/iwl-led.c b/drivers/net/wireless/iwlwifi/iwl-led.c index cb11c4a4d691..4eee1b163cd2 100644 --- a/drivers/net/wireless/iwlwifi/iwl-led.c +++ b/drivers/net/wireless/iwlwifi/iwl-led.c | |||
@@ -27,7 +27,6 @@ | |||
27 | 27 | ||
28 | #include <linux/kernel.h> | 28 | #include <linux/kernel.h> |
29 | #include <linux/module.h> | 29 | #include <linux/module.h> |
30 | #include <linux/version.h> | ||
31 | #include <linux/init.h> | 30 | #include <linux/init.h> |
32 | #include <linux/pci.h> | 31 | #include <linux/pci.h> |
33 | #include <linux/dma-mapping.h> | 32 | #include <linux/dma-mapping.h> |
diff --git a/drivers/net/wireless/iwlwifi/iwl-power.c b/drivers/net/wireless/iwlwifi/iwl-power.c index 028e3053c0ca..a099c9e30e55 100644 --- a/drivers/net/wireless/iwlwifi/iwl-power.c +++ b/drivers/net/wireless/iwlwifi/iwl-power.c | |||
@@ -29,7 +29,6 @@ | |||
29 | 29 | ||
30 | #include <linux/kernel.h> | 30 | #include <linux/kernel.h> |
31 | #include <linux/module.h> | 31 | #include <linux/module.h> |
32 | #include <linux/version.h> | ||
33 | #include <linux/init.h> | 32 | #include <linux/init.h> |
34 | 33 | ||
35 | #include <net/mac80211.h> | 34 | #include <net/mac80211.h> |
diff --git a/drivers/net/wireless/iwlwifi/iwl-rfkill.c b/drivers/net/wireless/iwlwifi/iwl-rfkill.c index e5e5846e9f25..5d642298f04c 100644 --- a/drivers/net/wireless/iwlwifi/iwl-rfkill.c +++ b/drivers/net/wireless/iwlwifi/iwl-rfkill.c | |||
@@ -27,7 +27,6 @@ | |||
27 | *****************************************************************************/ | 27 | *****************************************************************************/ |
28 | #include <linux/kernel.h> | 28 | #include <linux/kernel.h> |
29 | #include <linux/module.h> | 29 | #include <linux/module.h> |
30 | #include <linux/version.h> | ||
31 | #include <linux/init.h> | 30 | #include <linux/init.h> |
32 | 31 | ||
33 | #include <net/mac80211.h> | 32 | #include <net/mac80211.h> |
diff --git a/drivers/net/wireless/iwlwifi/iwl-sta.c b/drivers/net/wireless/iwlwifi/iwl-sta.c index 60a6e0106036..6283a3a707f5 100644 --- a/drivers/net/wireless/iwlwifi/iwl-sta.c +++ b/drivers/net/wireless/iwlwifi/iwl-sta.c | |||
@@ -207,7 +207,7 @@ static void iwl_set_ht_add_station(struct iwl_priv *priv, u8 index, | |||
207 | case WLAN_HT_CAP_MIMO_PS_DISABLED: | 207 | case WLAN_HT_CAP_MIMO_PS_DISABLED: |
208 | break; | 208 | break; |
209 | default: | 209 | default: |
210 | IWL_WARNING("Invalid MIMO PS mode %d", mimo_ps_mode); | 210 | IWL_WARNING("Invalid MIMO PS mode %d\n", mimo_ps_mode); |
211 | break; | 211 | break; |
212 | } | 212 | } |
213 | 213 | ||
@@ -969,7 +969,7 @@ int iwl_get_sta_id(struct iwl_priv *priv, struct ieee80211_hdr *hdr) | |||
969 | return priv->hw_params.bcast_sta_id; | 969 | return priv->hw_params.bcast_sta_id; |
970 | 970 | ||
971 | default: | 971 | default: |
972 | IWL_WARNING("Unknown mode of operation: %d", priv->iw_mode); | 972 | IWL_WARNING("Unknown mode of operation: %d\n", priv->iw_mode); |
973 | return priv->hw_params.bcast_sta_id; | 973 | return priv->hw_params.bcast_sta_id; |
974 | } | 974 | } |
975 | } | 975 | } |
diff --git a/drivers/net/wireless/iwlwifi/iwl-tx.c b/drivers/net/wireless/iwlwifi/iwl-tx.c index 4108c7c8f00f..d82823b5c8ab 100644 --- a/drivers/net/wireless/iwlwifi/iwl-tx.c +++ b/drivers/net/wireless/iwlwifi/iwl-tx.c | |||
@@ -493,7 +493,7 @@ int iwl_txq_ctx_reset(struct iwl_priv *priv) | |||
493 | /* Alloc keep-warm buffer */ | 493 | /* Alloc keep-warm buffer */ |
494 | ret = iwl_kw_alloc(priv); | 494 | ret = iwl_kw_alloc(priv); |
495 | if (ret) { | 495 | if (ret) { |
496 | IWL_ERROR("Keep Warm allocation failed"); | 496 | IWL_ERROR("Keep Warm allocation failed\n"); |
497 | goto error_kw; | 497 | goto error_kw; |
498 | } | 498 | } |
499 | spin_lock_irqsave(&priv->lock, flags); | 499 | spin_lock_irqsave(&priv->lock, flags); |
@@ -1463,7 +1463,7 @@ void iwl_rx_reply_compressed_ba(struct iwl_priv *priv, | |||
1463 | u16 ba_resp_scd_ssn = le16_to_cpu(ba_resp->scd_ssn); | 1463 | u16 ba_resp_scd_ssn = le16_to_cpu(ba_resp->scd_ssn); |
1464 | 1464 | ||
1465 | if (scd_flow >= priv->hw_params.max_txq_num) { | 1465 | if (scd_flow >= priv->hw_params.max_txq_num) { |
1466 | IWL_ERROR("BUG_ON scd_flow is bigger than number of queues"); | 1466 | IWL_ERROR("BUG_ON scd_flow is bigger than number of queues\n"); |
1467 | return; | 1467 | return; |
1468 | } | 1468 | } |
1469 | 1469 | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c index 444847ab1b5a..b775d5bab668 100644 --- a/drivers/net/wireless/iwlwifi/iwl3945-base.c +++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c | |||
@@ -29,7 +29,6 @@ | |||
29 | 29 | ||
30 | #include <linux/kernel.h> | 30 | #include <linux/kernel.h> |
31 | #include <linux/module.h> | 31 | #include <linux/module.h> |
32 | #include <linux/version.h> | ||
33 | #include <linux/init.h> | 32 | #include <linux/init.h> |
34 | #include <linux/pci.h> | 33 | #include <linux/pci.h> |
35 | #include <linux/dma-mapping.h> | 34 | #include <linux/dma-mapping.h> |
@@ -1558,7 +1557,7 @@ int iwl3945_eeprom_init(struct iwl3945_priv *priv) | |||
1558 | BUILD_BUG_ON(sizeof(priv->eeprom) != IWL_EEPROM_IMAGE_SIZE); | 1557 | BUILD_BUG_ON(sizeof(priv->eeprom) != IWL_EEPROM_IMAGE_SIZE); |
1559 | 1558 | ||
1560 | if ((gp & CSR_EEPROM_GP_VALID_MSK) == CSR_EEPROM_GP_BAD_SIGNATURE) { | 1559 | if ((gp & CSR_EEPROM_GP_VALID_MSK) == CSR_EEPROM_GP_BAD_SIGNATURE) { |
1561 | IWL_ERROR("EEPROM not found, EEPROM_GP=0x%08x", gp); | 1560 | IWL_ERROR("EEPROM not found, EEPROM_GP=0x%08x\n", gp); |
1562 | return -ENOENT; | 1561 | return -ENOENT; |
1563 | } | 1562 | } |
1564 | 1563 | ||
@@ -1583,7 +1582,7 @@ int iwl3945_eeprom_init(struct iwl3945_priv *priv) | |||
1583 | } | 1582 | } |
1584 | 1583 | ||
1585 | if (!(r & CSR_EEPROM_REG_READ_VALID_MSK)) { | 1584 | if (!(r & CSR_EEPROM_REG_READ_VALID_MSK)) { |
1586 | IWL_ERROR("Time out reading EEPROM[%d]", addr); | 1585 | IWL_ERROR("Time out reading EEPROM[%d]\n", addr); |
1587 | return -ETIMEDOUT; | 1586 | return -ETIMEDOUT; |
1588 | } | 1587 | } |
1589 | e[addr / 2] = le16_to_cpu((__force __le16)(r >> 16)); | 1588 | e[addr / 2] = le16_to_cpu((__force __le16)(r >> 16)); |
@@ -2507,7 +2506,7 @@ static int iwl3945_get_sta_id(struct iwl3945_priv *priv, struct ieee80211_hdr *h | |||
2507 | return priv->hw_setting.bcast_sta_id; | 2506 | return priv->hw_setting.bcast_sta_id; |
2508 | 2507 | ||
2509 | default: | 2508 | default: |
2510 | IWL_WARNING("Unknown mode of operation: %d", priv->iw_mode); | 2509 | IWL_WARNING("Unknown mode of operation: %d\n", priv->iw_mode); |
2511 | return priv->hw_setting.bcast_sta_id; | 2510 | return priv->hw_setting.bcast_sta_id; |
2512 | } | 2511 | } |
2513 | } | 2512 | } |
diff --git a/drivers/net/wireless/p54/p54common.c b/drivers/net/wireless/p54/p54common.c index 83cd85e1f847..29be3dc8ee09 100644 --- a/drivers/net/wireless/p54/p54common.c +++ b/drivers/net/wireless/p54/p54common.c | |||
@@ -413,12 +413,12 @@ static void p54_rx_frame_sent(struct ieee80211_hw *dev, struct sk_buff *skb) | |||
413 | last_addr = range->end_addr; | 413 | last_addr = range->end_addr; |
414 | __skb_unlink(entry, &priv->tx_queue); | 414 | __skb_unlink(entry, &priv->tx_queue); |
415 | memset(&info->status, 0, sizeof(info->status)); | 415 | memset(&info->status, 0, sizeof(info->status)); |
416 | priv->tx_stats[skb_get_queue_mapping(skb)].len--; | ||
417 | entry_hdr = (struct p54_control_hdr *) entry->data; | 416 | entry_hdr = (struct p54_control_hdr *) entry->data; |
418 | entry_data = (struct p54_tx_control_allocdata *) entry_hdr->data; | 417 | entry_data = (struct p54_tx_control_allocdata *) entry_hdr->data; |
419 | if ((entry_hdr->magic1 & cpu_to_le16(0x4000)) != 0) | 418 | if ((entry_hdr->magic1 & cpu_to_le16(0x4000)) != 0) |
420 | pad = entry_data->align[0]; | 419 | pad = entry_data->align[0]; |
421 | 420 | ||
421 | priv->tx_stats[entry_data->hw_queue - 4].len--; | ||
422 | if (!(info->flags & IEEE80211_TX_CTL_NO_ACK)) { | 422 | if (!(info->flags & IEEE80211_TX_CTL_NO_ACK)) { |
423 | if (!(payload->status & 0x01)) | 423 | if (!(payload->status & 0x01)) |
424 | info->flags |= IEEE80211_TX_STAT_ACK; | 424 | info->flags |= IEEE80211_TX_STAT_ACK; |
@@ -557,6 +557,7 @@ static int p54_tx(struct ieee80211_hw *dev, struct sk_buff *skb) | |||
557 | struct p54_tx_control_allocdata *txhdr; | 557 | struct p54_tx_control_allocdata *txhdr; |
558 | size_t padding, len; | 558 | size_t padding, len; |
559 | u8 rate; | 559 | u8 rate; |
560 | u8 cts_rate = 0x20; | ||
560 | 561 | ||
561 | current_queue = &priv->tx_stats[skb_get_queue_mapping(skb)]; | 562 | current_queue = &priv->tx_stats[skb_get_queue_mapping(skb)]; |
562 | if (unlikely(current_queue->len > current_queue->limit)) | 563 | if (unlikely(current_queue->len > current_queue->limit)) |
@@ -581,28 +582,28 @@ static int p54_tx(struct ieee80211_hw *dev, struct sk_buff *skb) | |||
581 | hdr->type = (info->flags & IEEE80211_TX_CTL_NO_ACK) ? 0 : cpu_to_le16(1); | 582 | hdr->type = (info->flags & IEEE80211_TX_CTL_NO_ACK) ? 0 : cpu_to_le16(1); |
582 | hdr->retry1 = hdr->retry2 = info->control.retry_limit; | 583 | hdr->retry1 = hdr->retry2 = info->control.retry_limit; |
583 | 584 | ||
584 | memset(txhdr->wep_key, 0x0, 16); | ||
585 | txhdr->padding = 0; | ||
586 | txhdr->padding2 = 0; | ||
587 | |||
588 | /* TODO: add support for alternate retry TX rates */ | 585 | /* TODO: add support for alternate retry TX rates */ |
589 | rate = ieee80211_get_tx_rate(dev, info)->hw_value; | 586 | rate = ieee80211_get_tx_rate(dev, info)->hw_value; |
590 | if (info->flags & IEEE80211_TX_CTL_SHORT_PREAMBLE) | 587 | if (info->flags & IEEE80211_TX_CTL_SHORT_PREAMBLE) { |
591 | rate |= 0x10; | 588 | rate |= 0x10; |
592 | if (info->flags & IEEE80211_TX_CTL_USE_RTS_CTS) | 589 | cts_rate |= 0x10; |
590 | } | ||
591 | if (info->flags & IEEE80211_TX_CTL_USE_RTS_CTS) { | ||
593 | rate |= 0x40; | 592 | rate |= 0x40; |
594 | else if (info->flags & IEEE80211_TX_CTL_USE_CTS_PROTECT) | 593 | cts_rate |= ieee80211_get_rts_cts_rate(dev, info)->hw_value; |
594 | } else if (info->flags & IEEE80211_TX_CTL_USE_CTS_PROTECT) { | ||
595 | rate |= 0x20; | 595 | rate |= 0x20; |
596 | cts_rate |= ieee80211_get_rts_cts_rate(dev, info)->hw_value; | ||
597 | } | ||
596 | memset(txhdr->rateset, rate, 8); | 598 | memset(txhdr->rateset, rate, 8); |
597 | txhdr->wep_key_present = 0; | 599 | txhdr->key_type = 0; |
598 | txhdr->wep_key_len = 0; | 600 | txhdr->key_len = 0; |
599 | txhdr->frame_type = cpu_to_le32(skb_get_queue_mapping(skb) + 4); | 601 | txhdr->hw_queue = skb_get_queue_mapping(skb) + 4; |
600 | txhdr->magic4 = 0; | 602 | txhdr->tx_antenna = (info->antenna_sel_tx == 0) ? |
601 | txhdr->antenna = (info->antenna_sel_tx == 0) ? | ||
602 | 2 : info->antenna_sel_tx - 1; | 603 | 2 : info->antenna_sel_tx - 1; |
603 | txhdr->output_power = 0x7f; // HW Maximum | 604 | txhdr->output_power = 0x7f; // HW Maximum |
604 | txhdr->magic5 = (info->flags & IEEE80211_TX_CTL_NO_ACK) ? | 605 | txhdr->cts_rate = (info->flags & IEEE80211_TX_CTL_NO_ACK) ? |
605 | 0 : ((rate > 0x3) ? cpu_to_le32(0x33) : cpu_to_le32(0x23)); | 606 | 0 : cts_rate; |
606 | if (padding) | 607 | if (padding) |
607 | txhdr->align[0] = padding; | 608 | txhdr->align[0] = padding; |
608 | 609 | ||
@@ -836,10 +837,21 @@ static int p54_start(struct ieee80211_hw *dev) | |||
836 | struct p54_common *priv = dev->priv; | 837 | struct p54_common *priv = dev->priv; |
837 | int err; | 838 | int err; |
838 | 839 | ||
840 | if (!priv->cached_vdcf) { | ||
841 | priv->cached_vdcf = kzalloc(sizeof(struct p54_tx_control_vdcf)+ | ||
842 | priv->tx_hdr_len + sizeof(struct p54_control_hdr), | ||
843 | GFP_KERNEL); | ||
844 | |||
845 | if (!priv->cached_vdcf) | ||
846 | return -ENOMEM; | ||
847 | } | ||
848 | |||
839 | err = priv->open(dev); | 849 | err = priv->open(dev); |
840 | if (!err) | 850 | if (!err) |
841 | priv->mode = IEEE80211_IF_TYPE_MNTR; | 851 | priv->mode = IEEE80211_IF_TYPE_MNTR; |
842 | 852 | ||
853 | p54_init_vdcf(dev); | ||
854 | |||
843 | return err; | 855 | return err; |
844 | } | 856 | } |
845 | 857 | ||
@@ -1019,15 +1031,6 @@ struct ieee80211_hw *p54_init_common(size_t priv_data_len) | |||
1019 | dev->extra_tx_headroom = sizeof(struct p54_control_hdr) + 4 + | 1031 | dev->extra_tx_headroom = sizeof(struct p54_control_hdr) + 4 + |
1020 | sizeof(struct p54_tx_control_allocdata); | 1032 | sizeof(struct p54_tx_control_allocdata); |
1021 | 1033 | ||
1022 | priv->cached_vdcf = kzalloc(sizeof(struct p54_tx_control_vdcf) + | ||
1023 | priv->tx_hdr_len + sizeof(struct p54_control_hdr), GFP_KERNEL); | ||
1024 | |||
1025 | if (!priv->cached_vdcf) { | ||
1026 | ieee80211_free_hw(dev); | ||
1027 | return NULL; | ||
1028 | } | ||
1029 | |||
1030 | p54_init_vdcf(dev); | ||
1031 | mutex_init(&priv->conf_mutex); | 1034 | mutex_init(&priv->conf_mutex); |
1032 | 1035 | ||
1033 | return dev; | 1036 | return dev; |
diff --git a/drivers/net/wireless/p54/p54common.h b/drivers/net/wireless/p54/p54common.h index 2245fcce92dc..8db6c0e8e540 100644 --- a/drivers/net/wireless/p54/p54common.h +++ b/drivers/net/wireless/p54/p54common.h | |||
@@ -183,16 +183,16 @@ struct p54_frame_sent_hdr { | |||
183 | 183 | ||
184 | struct p54_tx_control_allocdata { | 184 | struct p54_tx_control_allocdata { |
185 | u8 rateset[8]; | 185 | u8 rateset[8]; |
186 | u16 padding; | 186 | u8 unalloc0[2]; |
187 | u8 wep_key_present; | 187 | u8 key_type; |
188 | u8 wep_key_len; | 188 | u8 key_len; |
189 | u8 wep_key[16]; | 189 | u8 key[16]; |
190 | __le32 frame_type; | 190 | u8 hw_queue; |
191 | u32 padding2; | 191 | u8 unalloc1[9]; |
192 | __le16 magic4; | 192 | u8 tx_antenna; |
193 | u8 antenna; | ||
194 | u8 output_power; | 193 | u8 output_power; |
195 | __le32 magic5; | 194 | u8 cts_rate; |
195 | u8 unalloc2[3]; | ||
196 | u8 align[0]; | 196 | u8 align[0]; |
197 | } __attribute__ ((packed)); | 197 | } __attribute__ ((packed)); |
198 | 198 | ||
diff --git a/drivers/net/wireless/p54/p54usb.c b/drivers/net/wireless/p54/p54usb.c index 815c095ef797..cbaca23a9453 100644 --- a/drivers/net/wireless/p54/p54usb.c +++ b/drivers/net/wireless/p54/p54usb.c | |||
@@ -109,7 +109,17 @@ static void p54u_rx_cb(struct urb *urb) | |||
109 | urb->context = skb; | 109 | urb->context = skb; |
110 | skb_queue_tail(&priv->rx_queue, skb); | 110 | skb_queue_tail(&priv->rx_queue, skb); |
111 | } else { | 111 | } else { |
112 | if (!priv->hw_type) | ||
113 | skb_push(skb, sizeof(struct net2280_tx_hdr)); | ||
114 | |||
115 | skb_reset_tail_pointer(skb); | ||
112 | skb_trim(skb, 0); | 116 | skb_trim(skb, 0); |
117 | if (urb->transfer_buffer != skb_tail_pointer(skb)) { | ||
118 | /* this should not happen */ | ||
119 | WARN_ON(1); | ||
120 | urb->transfer_buffer = skb_tail_pointer(skb); | ||
121 | } | ||
122 | |||
113 | skb_queue_tail(&priv->rx_queue, skb); | 123 | skb_queue_tail(&priv->rx_queue, skb); |
114 | } | 124 | } |
115 | 125 | ||
diff --git a/drivers/net/wireless/rt2x00/rt2x00queue.h b/drivers/net/wireless/rt2x00/rt2x00queue.h index a4a8c57004db..ff78e52ce43c 100644 --- a/drivers/net/wireless/rt2x00/rt2x00queue.h +++ b/drivers/net/wireless/rt2x00/rt2x00queue.h | |||
@@ -173,10 +173,10 @@ struct rxdone_entry_desc { | |||
173 | * frame transmission failed due to excessive retries. | 173 | * frame transmission failed due to excessive retries. |
174 | */ | 174 | */ |
175 | enum txdone_entry_desc_flags { | 175 | enum txdone_entry_desc_flags { |
176 | TXDONE_UNKNOWN = 1 << 0, | 176 | TXDONE_UNKNOWN, |
177 | TXDONE_SUCCESS = 1 << 1, | 177 | TXDONE_SUCCESS, |
178 | TXDONE_FAILURE = 1 << 2, | 178 | TXDONE_FAILURE, |
179 | TXDONE_EXCESSIVE_RETRY = 1 << 3, | 179 | TXDONE_EXCESSIVE_RETRY, |
180 | }; | 180 | }; |
181 | 181 | ||
182 | /** | 182 | /** |
diff --git a/drivers/net/wireless/rt2x00/rt2x00usb.c b/drivers/net/wireless/rt2x00/rt2x00usb.c index 8d76bb2e0312..2050227ea530 100644 --- a/drivers/net/wireless/rt2x00/rt2x00usb.c +++ b/drivers/net/wireless/rt2x00/rt2x00usb.c | |||
@@ -181,6 +181,7 @@ static void rt2x00usb_interrupt_txdone(struct urb *urb) | |||
181 | * (Only indirectly by looking at the failed TX counters | 181 | * (Only indirectly by looking at the failed TX counters |
182 | * in the register). | 182 | * in the register). |
183 | */ | 183 | */ |
184 | txdesc.flags = 0; | ||
184 | if (!urb->status) | 185 | if (!urb->status) |
185 | __set_bit(TXDONE_UNKNOWN, &txdesc.flags); | 186 | __set_bit(TXDONE_UNKNOWN, &txdesc.flags); |
186 | else | 187 | else |
diff --git a/drivers/net/wireless/rtl8187_dev.c b/drivers/net/wireless/rtl8187_dev.c index 57376fb993ed..ca5deb6244e6 100644 --- a/drivers/net/wireless/rtl8187_dev.c +++ b/drivers/net/wireless/rtl8187_dev.c | |||
@@ -40,6 +40,7 @@ static struct usb_device_id rtl8187_table[] __devinitdata = { | |||
40 | /* Netgear */ | 40 | /* Netgear */ |
41 | {USB_DEVICE(0x0846, 0x6100), .driver_info = DEVICE_RTL8187}, | 41 | {USB_DEVICE(0x0846, 0x6100), .driver_info = DEVICE_RTL8187}, |
42 | {USB_DEVICE(0x0846, 0x6a00), .driver_info = DEVICE_RTL8187}, | 42 | {USB_DEVICE(0x0846, 0x6a00), .driver_info = DEVICE_RTL8187}, |
43 | {USB_DEVICE(0x0846, 0x4260), .driver_info = DEVICE_RTL8187B}, | ||
43 | /* HP */ | 44 | /* HP */ |
44 | {USB_DEVICE(0x03f0, 0xca02), .driver_info = DEVICE_RTL8187}, | 45 | {USB_DEVICE(0x03f0, 0xca02), .driver_info = DEVICE_RTL8187}, |
45 | /* Sitecom */ | 46 | /* Sitecom */ |