diff options
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r-- | drivers/net/wireless/arlan-proc.c | 8 | ||||
-rw-r--r-- | drivers/net/wireless/b43/debugfs.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/b43/dma.c | 37 | ||||
-rw-r--r-- | drivers/net/wireless/b43/main.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/b43/pcmcia.c | 6 | ||||
-rw-r--r-- | drivers/net/wireless/hostap/hostap_80211_rx.c | 39 | ||||
-rw-r--r-- | drivers/net/wireless/hostap/hostap_80211_tx.c | 7 | ||||
-rw-r--r-- | drivers/net/wireless/hostap/hostap_ap.c | 203 | ||||
-rw-r--r-- | drivers/net/wireless/ipw2200.c | 8 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/Kconfig | 5 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-4965.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl3945-base.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl4965-base.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/libertas/assoc.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/libertas/if_cs.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2x00dev.c | 13 | ||||
-rw-r--r-- | drivers/net/wireless/rt2x00/rt61pci.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/rt2x00/rt73usb.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/wavelan_cs.h | 2 |
19 files changed, 214 insertions, 140 deletions
diff --git a/drivers/net/wireless/arlan-proc.c b/drivers/net/wireless/arlan-proc.c index c6e70dbc5de8..2ab1d59870f4 100644 --- a/drivers/net/wireless/arlan-proc.c +++ b/drivers/net/wireless/arlan-proc.c | |||
@@ -1202,13 +1202,6 @@ static ctl_table arlan_table[MAX_ARLANS + 1] = | |||
1202 | { .ctl_name = 0 } | 1202 | { .ctl_name = 0 } |
1203 | }; | 1203 | }; |
1204 | #endif | 1204 | #endif |
1205 | #else | ||
1206 | |||
1207 | static ctl_table arlan_table[MAX_ARLANS + 1] = | ||
1208 | { | ||
1209 | { .ctl_name = 0 } | ||
1210 | }; | ||
1211 | #endif | ||
1212 | 1205 | ||
1213 | 1206 | ||
1214 | // static int mmtu = 1234; | 1207 | // static int mmtu = 1234; |
@@ -1233,7 +1226,6 @@ static ctl_table arlan_root_table[] = | |||
1233 | //}; | 1226 | //}; |
1234 | 1227 | ||
1235 | 1228 | ||
1236 | #ifdef CONFIG_PROC_FS | ||
1237 | static struct ctl_table_header *arlan_device_sysctl_header; | 1229 | static struct ctl_table_header *arlan_device_sysctl_header; |
1238 | 1230 | ||
1239 | int __init init_arlan_proc(void) | 1231 | int __init init_arlan_proc(void) |
diff --git a/drivers/net/wireless/b43/debugfs.c b/drivers/net/wireless/b43/debugfs.c index e38ed0fe72e9..7fca2ebc747f 100644 --- a/drivers/net/wireless/b43/debugfs.c +++ b/drivers/net/wireless/b43/debugfs.c | |||
@@ -618,6 +618,7 @@ void b43_debugfs_remove_device(struct b43_wldev *dev) | |||
618 | kfree(e); | 618 | kfree(e); |
619 | } | 619 | } |
620 | 620 | ||
621 | /* Called with IRQs disabled. */ | ||
621 | void b43_debugfs_log_txstat(struct b43_wldev *dev, | 622 | void b43_debugfs_log_txstat(struct b43_wldev *dev, |
622 | const struct b43_txstatus *status) | 623 | const struct b43_txstatus *status) |
623 | { | 624 | { |
@@ -629,8 +630,7 @@ void b43_debugfs_log_txstat(struct b43_wldev *dev, | |||
629 | if (!e) | 630 | if (!e) |
630 | return; | 631 | return; |
631 | log = &e->txstatlog; | 632 | log = &e->txstatlog; |
632 | B43_WARN_ON(!irqs_disabled()); | 633 | spin_lock(&log->lock); /* IRQs are already disabled. */ |
633 | spin_lock(&log->lock); | ||
634 | i = log->end + 1; | 634 | i = log->end + 1; |
635 | if (i == B43_NR_LOGGED_TXSTATUS) | 635 | if (i == B43_NR_LOGGED_TXSTATUS) |
636 | i = 0; | 636 | i = 0; |
diff --git a/drivers/net/wireless/b43/dma.c b/drivers/net/wireless/b43/dma.c index 3dfb28a34be9..948eb1fe916b 100644 --- a/drivers/net/wireless/b43/dma.c +++ b/drivers/net/wireless/b43/dma.c | |||
@@ -560,7 +560,7 @@ static int b43_dmacontroller_tx_reset(struct b43_wldev *dev, u16 mmio_base, | |||
560 | /* Check if a DMA mapping address is invalid. */ | 560 | /* Check if a DMA mapping address is invalid. */ |
561 | static bool b43_dma_mapping_error(struct b43_dmaring *ring, | 561 | static bool b43_dma_mapping_error(struct b43_dmaring *ring, |
562 | dma_addr_t addr, | 562 | dma_addr_t addr, |
563 | size_t buffersize) | 563 | size_t buffersize, bool dma_to_device) |
564 | { | 564 | { |
565 | if (unlikely(dma_mapping_error(addr))) | 565 | if (unlikely(dma_mapping_error(addr))) |
566 | return 1; | 566 | return 1; |
@@ -568,11 +568,11 @@ static bool b43_dma_mapping_error(struct b43_dmaring *ring, | |||
568 | switch (ring->type) { | 568 | switch (ring->type) { |
569 | case B43_DMA_30BIT: | 569 | case B43_DMA_30BIT: |
570 | if ((u64)addr + buffersize > (1ULL << 30)) | 570 | if ((u64)addr + buffersize > (1ULL << 30)) |
571 | return 1; | 571 | goto address_error; |
572 | break; | 572 | break; |
573 | case B43_DMA_32BIT: | 573 | case B43_DMA_32BIT: |
574 | if ((u64)addr + buffersize > (1ULL << 32)) | 574 | if ((u64)addr + buffersize > (1ULL << 32)) |
575 | return 1; | 575 | goto address_error; |
576 | break; | 576 | break; |
577 | case B43_DMA_64BIT: | 577 | case B43_DMA_64BIT: |
578 | /* Currently we can't have addresses beyond | 578 | /* Currently we can't have addresses beyond |
@@ -582,6 +582,12 @@ static bool b43_dma_mapping_error(struct b43_dmaring *ring, | |||
582 | 582 | ||
583 | /* The address is OK. */ | 583 | /* The address is OK. */ |
584 | return 0; | 584 | return 0; |
585 | |||
586 | address_error: | ||
587 | /* We can't support this address. Unmap it again. */ | ||
588 | unmap_descbuffer(ring, addr, buffersize, dma_to_device); | ||
589 | |||
590 | return 1; | ||
585 | } | 591 | } |
586 | 592 | ||
587 | static int setup_rx_descbuffer(struct b43_dmaring *ring, | 593 | static int setup_rx_descbuffer(struct b43_dmaring *ring, |
@@ -599,7 +605,7 @@ static int setup_rx_descbuffer(struct b43_dmaring *ring, | |||
599 | if (unlikely(!skb)) | 605 | if (unlikely(!skb)) |
600 | return -ENOMEM; | 606 | return -ENOMEM; |
601 | dmaaddr = map_descbuffer(ring, skb->data, ring->rx_buffersize, 0); | 607 | dmaaddr = map_descbuffer(ring, skb->data, ring->rx_buffersize, 0); |
602 | if (b43_dma_mapping_error(ring, dmaaddr, ring->rx_buffersize)) { | 608 | if (b43_dma_mapping_error(ring, dmaaddr, ring->rx_buffersize, 0)) { |
603 | /* ugh. try to realloc in zone_dma */ | 609 | /* ugh. try to realloc in zone_dma */ |
604 | gfp_flags |= GFP_DMA; | 610 | gfp_flags |= GFP_DMA; |
605 | 611 | ||
@@ -612,7 +618,8 @@ static int setup_rx_descbuffer(struct b43_dmaring *ring, | |||
612 | ring->rx_buffersize, 0); | 618 | ring->rx_buffersize, 0); |
613 | } | 619 | } |
614 | 620 | ||
615 | if (b43_dma_mapping_error(ring, dmaaddr, ring->rx_buffersize)) { | 621 | if (b43_dma_mapping_error(ring, dmaaddr, ring->rx_buffersize, 0)) { |
622 | b43err(ring->dev->wl, "RX DMA buffer allocation failed\n"); | ||
616 | dev_kfree_skb_any(skb); | 623 | dev_kfree_skb_any(skb); |
617 | return -EIO; | 624 | return -EIO; |
618 | } | 625 | } |
@@ -852,7 +859,8 @@ struct b43_dmaring *b43_setup_dmaring(struct b43_wldev *dev, | |||
852 | b43_txhdr_size(dev), | 859 | b43_txhdr_size(dev), |
853 | DMA_TO_DEVICE); | 860 | DMA_TO_DEVICE); |
854 | 861 | ||
855 | if (b43_dma_mapping_error(ring, dma_test, b43_txhdr_size(dev))) { | 862 | if (b43_dma_mapping_error(ring, dma_test, |
863 | b43_txhdr_size(dev), 1)) { | ||
856 | /* ugh realloc */ | 864 | /* ugh realloc */ |
857 | kfree(ring->txhdr_cache); | 865 | kfree(ring->txhdr_cache); |
858 | ring->txhdr_cache = kcalloc(nr_slots, | 866 | ring->txhdr_cache = kcalloc(nr_slots, |
@@ -867,8 +875,12 @@ struct b43_dmaring *b43_setup_dmaring(struct b43_wldev *dev, | |||
867 | DMA_TO_DEVICE); | 875 | DMA_TO_DEVICE); |
868 | 876 | ||
869 | if (b43_dma_mapping_error(ring, dma_test, | 877 | if (b43_dma_mapping_error(ring, dma_test, |
870 | b43_txhdr_size(dev))) | 878 | b43_txhdr_size(dev), 1)) { |
879 | |||
880 | b43err(dev->wl, | ||
881 | "TXHDR DMA allocation failed\n"); | ||
871 | goto err_kfree_txhdr_cache; | 882 | goto err_kfree_txhdr_cache; |
883 | } | ||
872 | } | 884 | } |
873 | 885 | ||
874 | dma_unmap_single(dev->dev->dev, | 886 | dma_unmap_single(dev->dev->dev, |
@@ -1189,7 +1201,7 @@ static int dma_tx_fragment(struct b43_dmaring *ring, | |||
1189 | 1201 | ||
1190 | meta_hdr->dmaaddr = map_descbuffer(ring, (unsigned char *)header, | 1202 | meta_hdr->dmaaddr = map_descbuffer(ring, (unsigned char *)header, |
1191 | hdrsize, 1); | 1203 | hdrsize, 1); |
1192 | if (b43_dma_mapping_error(ring, meta_hdr->dmaaddr, hdrsize)) { | 1204 | if (b43_dma_mapping_error(ring, meta_hdr->dmaaddr, hdrsize, 1)) { |
1193 | ring->current_slot = old_top_slot; | 1205 | ring->current_slot = old_top_slot; |
1194 | ring->used_slots = old_used_slots; | 1206 | ring->used_slots = old_used_slots; |
1195 | return -EIO; | 1207 | return -EIO; |
@@ -1208,7 +1220,7 @@ static int dma_tx_fragment(struct b43_dmaring *ring, | |||
1208 | 1220 | ||
1209 | meta->dmaaddr = map_descbuffer(ring, skb->data, skb->len, 1); | 1221 | meta->dmaaddr = map_descbuffer(ring, skb->data, skb->len, 1); |
1210 | /* create a bounce buffer in zone_dma on mapping failure. */ | 1222 | /* create a bounce buffer in zone_dma on mapping failure. */ |
1211 | if (b43_dma_mapping_error(ring, meta->dmaaddr, skb->len)) { | 1223 | if (b43_dma_mapping_error(ring, meta->dmaaddr, skb->len, 1)) { |
1212 | bounce_skb = __dev_alloc_skb(skb->len, GFP_ATOMIC | GFP_DMA); | 1224 | bounce_skb = __dev_alloc_skb(skb->len, GFP_ATOMIC | GFP_DMA); |
1213 | if (!bounce_skb) { | 1225 | if (!bounce_skb) { |
1214 | ring->current_slot = old_top_slot; | 1226 | ring->current_slot = old_top_slot; |
@@ -1222,7 +1234,7 @@ static int dma_tx_fragment(struct b43_dmaring *ring, | |||
1222 | skb = bounce_skb; | 1234 | skb = bounce_skb; |
1223 | meta->skb = skb; | 1235 | meta->skb = skb; |
1224 | meta->dmaaddr = map_descbuffer(ring, skb->data, skb->len, 1); | 1236 | meta->dmaaddr = map_descbuffer(ring, skb->data, skb->len, 1); |
1225 | if (b43_dma_mapping_error(ring, meta->dmaaddr, skb->len)) { | 1237 | if (b43_dma_mapping_error(ring, meta->dmaaddr, skb->len, 1)) { |
1226 | ring->current_slot = old_top_slot; | 1238 | ring->current_slot = old_top_slot; |
1227 | ring->used_slots = old_used_slots; | 1239 | ring->used_slots = old_used_slots; |
1228 | err = -EIO; | 1240 | err = -EIO; |
@@ -1337,6 +1349,7 @@ out_unlock: | |||
1337 | return err; | 1349 | return err; |
1338 | } | 1350 | } |
1339 | 1351 | ||
1352 | /* Called with IRQs disabled. */ | ||
1340 | void b43_dma_handle_txstatus(struct b43_wldev *dev, | 1353 | void b43_dma_handle_txstatus(struct b43_wldev *dev, |
1341 | const struct b43_txstatus *status) | 1354 | const struct b43_txstatus *status) |
1342 | { | 1355 | { |
@@ -1349,8 +1362,8 @@ void b43_dma_handle_txstatus(struct b43_wldev *dev, | |||
1349 | ring = parse_cookie(dev, status->cookie, &slot); | 1362 | ring = parse_cookie(dev, status->cookie, &slot); |
1350 | if (unlikely(!ring)) | 1363 | if (unlikely(!ring)) |
1351 | return; | 1364 | return; |
1352 | B43_WARN_ON(!irqs_disabled()); | 1365 | |
1353 | spin_lock(&ring->lock); | 1366 | spin_lock(&ring->lock); /* IRQs are already disabled. */ |
1354 | 1367 | ||
1355 | B43_WARN_ON(!ring->tx); | 1368 | B43_WARN_ON(!ring->tx); |
1356 | ops = ring->ops; | 1369 | ops = ring->ops; |
diff --git a/drivers/net/wireless/b43/main.c b/drivers/net/wireless/b43/main.c index 51dfce16178a..c73a75b24cd6 100644 --- a/drivers/net/wireless/b43/main.c +++ b/drivers/net/wireless/b43/main.c | |||
@@ -2049,7 +2049,6 @@ void b43_mac_enable(struct b43_wldev *dev) | |||
2049 | { | 2049 | { |
2050 | dev->mac_suspended--; | 2050 | dev->mac_suspended--; |
2051 | B43_WARN_ON(dev->mac_suspended < 0); | 2051 | B43_WARN_ON(dev->mac_suspended < 0); |
2052 | B43_WARN_ON(irqs_disabled()); | ||
2053 | if (dev->mac_suspended == 0) { | 2052 | if (dev->mac_suspended == 0) { |
2054 | b43_write32(dev, B43_MMIO_MACCTL, | 2053 | b43_write32(dev, B43_MMIO_MACCTL, |
2055 | b43_read32(dev, B43_MMIO_MACCTL) | 2054 | b43_read32(dev, B43_MMIO_MACCTL) |
@@ -2075,7 +2074,6 @@ void b43_mac_suspend(struct b43_wldev *dev) | |||
2075 | u32 tmp; | 2074 | u32 tmp; |
2076 | 2075 | ||
2077 | might_sleep(); | 2076 | might_sleep(); |
2078 | B43_WARN_ON(irqs_disabled()); | ||
2079 | B43_WARN_ON(dev->mac_suspended < 0); | 2077 | B43_WARN_ON(dev->mac_suspended < 0); |
2080 | 2078 | ||
2081 | if (dev->mac_suspended == 0) { | 2079 | if (dev->mac_suspended == 0) { |
diff --git a/drivers/net/wireless/b43/pcmcia.c b/drivers/net/wireless/b43/pcmcia.c index b79a6bd5396d..371e4a119511 100644 --- a/drivers/net/wireless/b43/pcmcia.c +++ b/drivers/net/wireless/b43/pcmcia.c | |||
@@ -91,6 +91,8 @@ static int __devinit b43_pcmcia_probe(struct pcmcia_device *dev) | |||
91 | 91 | ||
92 | dev->conf.ConfigBase = parse.config.base; | 92 | dev->conf.ConfigBase = parse.config.base; |
93 | dev->conf.Present = parse.config.rmask[0]; | 93 | dev->conf.Present = parse.config.rmask[0]; |
94 | dev->conf.Attributes = CONF_ENABLE_IRQ; | ||
95 | dev->conf.IntType = INT_MEMORY_AND_IO; | ||
94 | 96 | ||
95 | dev->io.BasePort2 = 0; | 97 | dev->io.BasePort2 = 0; |
96 | dev->io.NumPorts2 = 0; | 98 | dev->io.NumPorts2 = 0; |
@@ -112,8 +114,8 @@ static int __devinit b43_pcmcia_probe(struct pcmcia_device *dev) | |||
112 | if (res != CS_SUCCESS) | 114 | if (res != CS_SUCCESS) |
113 | goto err_disable; | 115 | goto err_disable; |
114 | 116 | ||
115 | dev->irq.Attributes = IRQ_TYPE_DYNAMIC_SHARING | IRQ_FIRST_SHARED; | 117 | dev->irq.Attributes = IRQ_TYPE_DYNAMIC_SHARING; |
116 | dev->irq.IRQInfo1 = IRQ_LEVEL_ID | IRQ_SHARE_ID; | 118 | dev->irq.IRQInfo1 = IRQ_LEVEL_ID; |
117 | dev->irq.Handler = NULL; /* The handler is registered later. */ | 119 | dev->irq.Handler = NULL; /* The handler is registered later. */ |
118 | dev->irq.Instance = NULL; | 120 | dev->irq.Instance = NULL; |
119 | res = pcmcia_request_irq(dev, &dev->irq); | 121 | res = pcmcia_request_irq(dev, &dev->irq); |
diff --git a/drivers/net/wireless/hostap/hostap_80211_rx.c b/drivers/net/wireless/hostap/hostap_80211_rx.c index 49978bdb4324..4fd73809602e 100644 --- a/drivers/net/wireless/hostap/hostap_80211_rx.c +++ b/drivers/net/wireless/hostap/hostap_80211_rx.c | |||
@@ -635,7 +635,6 @@ hostap_rx_frame_decrypt(local_info_t *local, struct sk_buff *skb, | |||
635 | { | 635 | { |
636 | struct ieee80211_hdr_4addr *hdr; | 636 | struct ieee80211_hdr_4addr *hdr; |
637 | int res, hdrlen; | 637 | int res, hdrlen; |
638 | DECLARE_MAC_BUF(mac); | ||
639 | 638 | ||
640 | if (crypt == NULL || crypt->ops->decrypt_mpdu == NULL) | 639 | if (crypt == NULL || crypt->ops->decrypt_mpdu == NULL) |
641 | return 0; | 640 | return 0; |
@@ -647,8 +646,10 @@ hostap_rx_frame_decrypt(local_info_t *local, struct sk_buff *skb, | |||
647 | strcmp(crypt->ops->name, "TKIP") == 0) { | 646 | strcmp(crypt->ops->name, "TKIP") == 0) { |
648 | if (net_ratelimit()) { | 647 | if (net_ratelimit()) { |
649 | printk(KERN_DEBUG "%s: TKIP countermeasures: dropped " | 648 | printk(KERN_DEBUG "%s: TKIP countermeasures: dropped " |
650 | "received packet from %s\n", | 649 | "received packet from " MAC_FMT "\n", |
651 | local->dev->name, print_mac(mac, hdr->addr2)); | 650 | local->dev->name, |
651 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], | ||
652 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5]); | ||
652 | } | 653 | } |
653 | return -1; | 654 | return -1; |
654 | } | 655 | } |
@@ -657,9 +658,12 @@ hostap_rx_frame_decrypt(local_info_t *local, struct sk_buff *skb, | |||
657 | res = crypt->ops->decrypt_mpdu(skb, hdrlen, crypt->priv); | 658 | res = crypt->ops->decrypt_mpdu(skb, hdrlen, crypt->priv); |
658 | atomic_dec(&crypt->refcnt); | 659 | atomic_dec(&crypt->refcnt); |
659 | if (res < 0) { | 660 | if (res < 0) { |
660 | printk(KERN_DEBUG "%s: decryption failed (SA=%s" | 661 | printk(KERN_DEBUG "%s: decryption failed (SA=" MAC_FMT |
661 | ") res=%d\n", | 662 | ") res=%d\n", |
662 | local->dev->name, print_mac(mac, hdr->addr2), res); | 663 | local->dev->name, |
664 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], | ||
665 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5], | ||
666 | res); | ||
663 | local->comm_tallies.rx_discards_wep_undecryptable++; | 667 | local->comm_tallies.rx_discards_wep_undecryptable++; |
664 | return -1; | 668 | return -1; |
665 | } | 669 | } |
@@ -721,7 +725,6 @@ void hostap_80211_rx(struct net_device *dev, struct sk_buff *skb, | |||
721 | struct ieee80211_crypt_data *crypt = NULL; | 725 | struct ieee80211_crypt_data *crypt = NULL; |
722 | void *sta = NULL; | 726 | void *sta = NULL; |
723 | int keyidx = 0; | 727 | int keyidx = 0; |
724 | DECLARE_MAC_BUF(mac); | ||
725 | 728 | ||
726 | iface = netdev_priv(dev); | 729 | iface = netdev_priv(dev); |
727 | local = iface->local; | 730 | local = iface->local; |
@@ -798,8 +801,10 @@ void hostap_80211_rx(struct net_device *dev, struct sk_buff *skb, | |||
798 | * frames silently instead of filling system log with | 801 | * frames silently instead of filling system log with |
799 | * these reports. */ | 802 | * these reports. */ |
800 | printk(KERN_DEBUG "%s: WEP decryption failed (not set)" | 803 | printk(KERN_DEBUG "%s: WEP decryption failed (not set)" |
801 | " (SA=%s)\n", | 804 | " (SA=" MAC_FMT ")\n", |
802 | local->dev->name, print_mac(mac, hdr->addr2)); | 805 | local->dev->name, |
806 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], | ||
807 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5]); | ||
803 | #endif | 808 | #endif |
804 | local->comm_tallies.rx_discards_wep_undecryptable++; | 809 | local->comm_tallies.rx_discards_wep_undecryptable++; |
805 | goto rx_dropped; | 810 | goto rx_dropped; |
@@ -813,8 +818,9 @@ void hostap_80211_rx(struct net_device *dev, struct sk_buff *skb, | |||
813 | (keyidx = hostap_rx_frame_decrypt(local, skb, crypt)) < 0) | 818 | (keyidx = hostap_rx_frame_decrypt(local, skb, crypt)) < 0) |
814 | { | 819 | { |
815 | printk(KERN_DEBUG "%s: failed to decrypt mgmt::auth " | 820 | printk(KERN_DEBUG "%s: failed to decrypt mgmt::auth " |
816 | "from %s\n", dev->name, | 821 | "from " MAC_FMT "\n", dev->name, |
817 | print_mac(mac, hdr->addr2)); | 822 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], |
823 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5]); | ||
818 | /* TODO: could inform hostapd about this so that it | 824 | /* TODO: could inform hostapd about this so that it |
819 | * could send auth failure report */ | 825 | * could send auth failure report */ |
820 | goto rx_dropped; | 826 | goto rx_dropped; |
@@ -982,8 +988,10 @@ void hostap_80211_rx(struct net_device *dev, struct sk_buff *skb, | |||
982 | "unencrypted EAPOL frame\n", local->dev->name); | 988 | "unencrypted EAPOL frame\n", local->dev->name); |
983 | } else { | 989 | } else { |
984 | printk(KERN_DEBUG "%s: encryption configured, but RX " | 990 | printk(KERN_DEBUG "%s: encryption configured, but RX " |
985 | "frame not encrypted (SA=%s)\n", | 991 | "frame not encrypted (SA=" MAC_FMT ")\n", |
986 | local->dev->name, print_mac(mac, hdr->addr2)); | 992 | local->dev->name, |
993 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], | ||
994 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5]); | ||
987 | goto rx_dropped; | 995 | goto rx_dropped; |
988 | } | 996 | } |
989 | } | 997 | } |
@@ -992,9 +1000,10 @@ void hostap_80211_rx(struct net_device *dev, struct sk_buff *skb, | |||
992 | !hostap_is_eapol_frame(local, skb)) { | 1000 | !hostap_is_eapol_frame(local, skb)) { |
993 | if (net_ratelimit()) { | 1001 | if (net_ratelimit()) { |
994 | printk(KERN_DEBUG "%s: dropped unencrypted RX data " | 1002 | printk(KERN_DEBUG "%s: dropped unencrypted RX data " |
995 | "frame from %s" | 1003 | "frame from " MAC_FMT " (drop_unencrypted=1)\n", |
996 | " (drop_unencrypted=1)\n", | 1004 | dev->name, |
997 | dev->name, print_mac(mac, hdr->addr2)); | 1005 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], |
1006 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5]); | ||
998 | } | 1007 | } |
999 | goto rx_dropped; | 1008 | goto rx_dropped; |
1000 | } | 1009 | } |
diff --git a/drivers/net/wireless/hostap/hostap_80211_tx.c b/drivers/net/wireless/hostap/hostap_80211_tx.c index e7afc3ec3e6d..921c984416f8 100644 --- a/drivers/net/wireless/hostap/hostap_80211_tx.c +++ b/drivers/net/wireless/hostap/hostap_80211_tx.c | |||
@@ -314,7 +314,6 @@ static struct sk_buff * hostap_tx_encrypt(struct sk_buff *skb, | |||
314 | struct ieee80211_hdr_4addr *hdr; | 314 | struct ieee80211_hdr_4addr *hdr; |
315 | u16 fc; | 315 | u16 fc; |
316 | int prefix_len, postfix_len, hdr_len, res; | 316 | int prefix_len, postfix_len, hdr_len, res; |
317 | DECLARE_MAC_BUF(mac); | ||
318 | 317 | ||
319 | iface = netdev_priv(skb->dev); | 318 | iface = netdev_priv(skb->dev); |
320 | local = iface->local; | 319 | local = iface->local; |
@@ -329,8 +328,10 @@ static struct sk_buff * hostap_tx_encrypt(struct sk_buff *skb, | |||
329 | hdr = (struct ieee80211_hdr_4addr *) skb->data; | 328 | hdr = (struct ieee80211_hdr_4addr *) skb->data; |
330 | if (net_ratelimit()) { | 329 | if (net_ratelimit()) { |
331 | printk(KERN_DEBUG "%s: TKIP countermeasures: dropped " | 330 | printk(KERN_DEBUG "%s: TKIP countermeasures: dropped " |
332 | "TX packet to %s\n", | 331 | "TX packet to " MAC_FMT "\n", |
333 | local->dev->name, print_mac(mac, hdr->addr1)); | 332 | local->dev->name, |
333 | hdr->addr1[0], hdr->addr1[1], hdr->addr1[2], | ||
334 | hdr->addr1[3], hdr->addr1[4], hdr->addr1[5]); | ||
334 | } | 335 | } |
335 | kfree_skb(skb); | 336 | kfree_skb(skb); |
336 | return NULL; | 337 | return NULL; |
diff --git a/drivers/net/wireless/hostap/hostap_ap.c b/drivers/net/wireless/hostap/hostap_ap.c index ad040a3bb8a7..0acd9589c48c 100644 --- a/drivers/net/wireless/hostap/hostap_ap.c +++ b/drivers/net/wireless/hostap/hostap_ap.c | |||
@@ -632,7 +632,6 @@ static void hostap_ap_tx_cb_auth(struct sk_buff *skb, int ok, void *data) | |||
632 | __le16 *pos; | 632 | __le16 *pos; |
633 | struct sta_info *sta = NULL; | 633 | struct sta_info *sta = NULL; |
634 | char *txt = NULL; | 634 | char *txt = NULL; |
635 | DECLARE_MAC_BUF(mac); | ||
636 | 635 | ||
637 | if (ap->local->hostapd) { | 636 | if (ap->local->hostapd) { |
638 | dev_kfree_skb(skb); | 637 | dev_kfree_skb(skb); |
@@ -684,10 +683,12 @@ static void hostap_ap_tx_cb_auth(struct sk_buff *skb, int ok, void *data) | |||
684 | if (sta) | 683 | if (sta) |
685 | atomic_dec(&sta->users); | 684 | atomic_dec(&sta->users); |
686 | if (txt) { | 685 | if (txt) { |
687 | PDEBUG(DEBUG_AP, "%s: %s auth_cb - alg=%d " | 686 | PDEBUG(DEBUG_AP, "%s: " MAC_FMT " auth_cb - alg=%d " |
688 | "trans#=%d status=%d - %s\n", | 687 | "trans#=%d status=%d - %s\n", |
689 | dev->name, print_mac(mac, hdr->addr1), auth_alg, | 688 | dev->name, |
690 | auth_transaction, status, txt); | 689 | hdr->addr1[0], hdr->addr1[1], hdr->addr1[2], |
690 | hdr->addr1[3], hdr->addr1[4], hdr->addr1[5], | ||
691 | auth_alg, auth_transaction, status, txt); | ||
691 | } | 692 | } |
692 | dev_kfree_skb(skb); | 693 | dev_kfree_skb(skb); |
693 | } | 694 | } |
@@ -703,7 +704,6 @@ static void hostap_ap_tx_cb_assoc(struct sk_buff *skb, int ok, void *data) | |||
703 | __le16 *pos; | 704 | __le16 *pos; |
704 | struct sta_info *sta = NULL; | 705 | struct sta_info *sta = NULL; |
705 | char *txt = NULL; | 706 | char *txt = NULL; |
706 | DECLARE_MAC_BUF(mac); | ||
707 | 707 | ||
708 | if (ap->local->hostapd) { | 708 | if (ap->local->hostapd) { |
709 | dev_kfree_skb(skb); | 709 | dev_kfree_skb(skb); |
@@ -754,8 +754,11 @@ static void hostap_ap_tx_cb_assoc(struct sk_buff *skb, int ok, void *data) | |||
754 | if (sta) | 754 | if (sta) |
755 | atomic_dec(&sta->users); | 755 | atomic_dec(&sta->users); |
756 | if (txt) { | 756 | if (txt) { |
757 | PDEBUG(DEBUG_AP, "%s: %s assoc_cb - %s\n", | 757 | PDEBUG(DEBUG_AP, "%s: " MAC_FMT " assoc_cb - %s\n", |
758 | dev->name, print_mac(mac, hdr->addr1), txt); | 758 | dev->name, |
759 | hdr->addr1[0], hdr->addr1[1], hdr->addr1[2], | ||
760 | hdr->addr1[3], hdr->addr1[4], hdr->addr1[5], | ||
761 | txt); | ||
759 | } | 762 | } |
760 | dev_kfree_skb(skb); | 763 | dev_kfree_skb(skb); |
761 | } | 764 | } |
@@ -767,7 +770,6 @@ static void hostap_ap_tx_cb_poll(struct sk_buff *skb, int ok, void *data) | |||
767 | struct ap_data *ap = data; | 770 | struct ap_data *ap = data; |
768 | struct ieee80211_hdr_4addr *hdr; | 771 | struct ieee80211_hdr_4addr *hdr; |
769 | struct sta_info *sta; | 772 | struct sta_info *sta; |
770 | DECLARE_MAC_BUF(mac); | ||
771 | 773 | ||
772 | if (skb->len < 24) | 774 | if (skb->len < 24) |
773 | goto fail; | 775 | goto fail; |
@@ -779,9 +781,11 @@ static void hostap_ap_tx_cb_poll(struct sk_buff *skb, int ok, void *data) | |||
779 | sta->flags &= ~WLAN_STA_PENDING_POLL; | 781 | sta->flags &= ~WLAN_STA_PENDING_POLL; |
780 | spin_unlock(&ap->sta_table_lock); | 782 | spin_unlock(&ap->sta_table_lock); |
781 | } else { | 783 | } else { |
782 | PDEBUG(DEBUG_AP, "%s: STA %s" | 784 | PDEBUG(DEBUG_AP, "%s: STA " MAC_FMT |
783 | " did not ACK activity poll frame\n", | 785 | " did not ACK activity poll frame\n", |
784 | ap->local->dev->name, print_mac(mac, hdr->addr1)); | 786 | ap->local->dev->name, |
787 | hdr->addr1[0], hdr->addr1[1], hdr->addr1[2], | ||
788 | hdr->addr1[3], hdr->addr1[4], hdr->addr1[5]); | ||
785 | } | 789 | } |
786 | 790 | ||
787 | fail: | 791 | fail: |
@@ -1306,7 +1310,6 @@ static void handle_authen(local_info_t *local, struct sk_buff *skb, | |||
1306 | struct sta_info *sta = NULL; | 1310 | struct sta_info *sta = NULL; |
1307 | struct ieee80211_crypt_data *crypt; | 1311 | struct ieee80211_crypt_data *crypt; |
1308 | char *txt = ""; | 1312 | char *txt = ""; |
1309 | DECLARE_MAC_BUF(mac); | ||
1310 | 1313 | ||
1311 | len = skb->len - IEEE80211_MGMT_HDR_LEN; | 1314 | len = skb->len - IEEE80211_MGMT_HDR_LEN; |
1312 | 1315 | ||
@@ -1315,8 +1318,9 @@ static void handle_authen(local_info_t *local, struct sk_buff *skb, | |||
1315 | 1318 | ||
1316 | if (len < 6) { | 1319 | if (len < 6) { |
1317 | PDEBUG(DEBUG_AP, "%s: handle_authen - too short payload " | 1320 | PDEBUG(DEBUG_AP, "%s: handle_authen - too short payload " |
1318 | "(len=%d) from %s\n", dev->name, len, | 1321 | "(len=%d) from " MAC_FMT "\n", dev->name, len, |
1319 | print_mac(mac, hdr->addr2)); | 1322 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], |
1323 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5]); | ||
1320 | return; | 1324 | return; |
1321 | } | 1325 | } |
1322 | 1326 | ||
@@ -1381,8 +1385,10 @@ static void handle_authen(local_info_t *local, struct sk_buff *skb, | |||
1381 | if (time_after(jiffies, sta->u.ap.last_beacon + | 1385 | if (time_after(jiffies, sta->u.ap.last_beacon + |
1382 | (10 * sta->listen_interval * HZ) / 1024)) { | 1386 | (10 * sta->listen_interval * HZ) / 1024)) { |
1383 | PDEBUG(DEBUG_AP, "%s: no beacons received for a while," | 1387 | PDEBUG(DEBUG_AP, "%s: no beacons received for a while," |
1384 | " assuming AP %s is now STA\n", | 1388 | " assuming AP " MAC_FMT " is now STA\n", |
1385 | dev->name, print_mac(mac, sta->addr)); | 1389 | dev->name, |
1390 | sta->addr[0], sta->addr[1], sta->addr[2], | ||
1391 | sta->addr[3], sta->addr[4], sta->addr[5]); | ||
1386 | sta->ap = 0; | 1392 | sta->ap = 0; |
1387 | sta->flags = 0; | 1393 | sta->flags = 0; |
1388 | sta->u.sta.challenge = NULL; | 1394 | sta->u.sta.challenge = NULL; |
@@ -1497,10 +1503,13 @@ static void handle_authen(local_info_t *local, struct sk_buff *skb, | |||
1497 | } | 1503 | } |
1498 | 1504 | ||
1499 | if (resp) { | 1505 | if (resp) { |
1500 | PDEBUG(DEBUG_AP, "%s: %s auth (alg=%d " | 1506 | PDEBUG(DEBUG_AP, "%s: " MAC_FMT " auth (alg=%d " |
1501 | "trans#=%d stat=%d len=%d fc=%04x) ==> %d (%s)\n", | 1507 | "trans#=%d stat=%d len=%d fc=%04x) ==> %d (%s)\n", |
1502 | dev->name, print_mac(mac, hdr->addr2), auth_alg, | 1508 | dev->name, |
1503 | auth_transaction, status_code, len, fc, resp, txt); | 1509 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], |
1510 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5], | ||
1511 | auth_alg, auth_transaction, status_code, len, | ||
1512 | fc, resp, txt); | ||
1504 | } | 1513 | } |
1505 | } | 1514 | } |
1506 | 1515 | ||
@@ -1519,14 +1528,15 @@ static void handle_assoc(local_info_t *local, struct sk_buff *skb, | |||
1519 | int send_deauth = 0; | 1528 | int send_deauth = 0; |
1520 | char *txt = ""; | 1529 | char *txt = ""; |
1521 | u8 prev_ap[ETH_ALEN]; | 1530 | u8 prev_ap[ETH_ALEN]; |
1522 | DECLARE_MAC_BUF(mac); | ||
1523 | 1531 | ||
1524 | left = len = skb->len - IEEE80211_MGMT_HDR_LEN; | 1532 | left = len = skb->len - IEEE80211_MGMT_HDR_LEN; |
1525 | 1533 | ||
1526 | if (len < (reassoc ? 10 : 4)) { | 1534 | if (len < (reassoc ? 10 : 4)) { |
1527 | PDEBUG(DEBUG_AP, "%s: handle_assoc - too short payload " | 1535 | PDEBUG(DEBUG_AP, "%s: handle_assoc - too short payload " |
1528 | "(len=%d, reassoc=%d) from %s\n", | 1536 | "(len=%d, reassoc=%d) from " MAC_FMT "\n", |
1529 | dev->name, len, reassoc, print_mac(mac, hdr->addr2)); | 1537 | dev->name, len, reassoc, |
1538 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], | ||
1539 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5]); | ||
1530 | return; | 1540 | return; |
1531 | } | 1541 | } |
1532 | 1542 | ||
@@ -1603,9 +1613,12 @@ static void handle_assoc(local_info_t *local, struct sk_buff *skb, | |||
1603 | } | 1613 | } |
1604 | 1614 | ||
1605 | if (left > 0) { | 1615 | if (left > 0) { |
1606 | PDEBUG(DEBUG_AP, "%s: assoc from %s" | 1616 | PDEBUG(DEBUG_AP, "%s: assoc from " MAC_FMT |
1607 | " with extra data (%d bytes) [", | 1617 | " with extra data (%d bytes) [", |
1608 | dev->name, print_mac(mac, hdr->addr2), left); | 1618 | dev->name, |
1619 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], | ||
1620 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5], | ||
1621 | left); | ||
1609 | while (left > 0) { | 1622 | while (left > 0) { |
1610 | PDEBUG2(DEBUG_AP, "<%02x>", *u); | 1623 | PDEBUG2(DEBUG_AP, "<%02x>", *u); |
1611 | u++; left--; | 1624 | u++; left--; |
@@ -1704,10 +1717,15 @@ static void handle_assoc(local_info_t *local, struct sk_buff *skb, | |||
1704 | } | 1717 | } |
1705 | 1718 | ||
1706 | #if 0 | 1719 | #if 0 |
1707 | PDEBUG(DEBUG_AP, "%s: %s %sassoc (len=%d " | 1720 | PDEBUG(DEBUG_AP, "%s: " MAC_FMT" %sassoc (len=%d " |
1708 | "prev_ap=%s) => %d(%d) (%s)\n", | 1721 | "prev_ap=" MAC_FMT") => %d(%d) (%s)\n", |
1709 | dev->name, print_mac(mac, hdr->addr2), reassoc ? "re" : "", len, | 1722 | dev->name, |
1710 | print_mac(mac, prev_ap), resp, send_deauth, txt); | 1723 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], |
1724 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5], | ||
1725 | reassoc ? "re" : "", len, | ||
1726 | prev_ap[0], prev_ap[1], prev_ap[2], | ||
1727 | prev_ap[3], prev_ap[4], prev_ap[5], | ||
1728 | resp, send_deauth, txt); | ||
1711 | #endif | 1729 | #endif |
1712 | } | 1730 | } |
1713 | 1731 | ||
@@ -1735,9 +1753,11 @@ static void handle_deauth(local_info_t *local, struct sk_buff *skb, | |||
1735 | pos = (__le16 *) body; | 1753 | pos = (__le16 *) body; |
1736 | reason_code = le16_to_cpu(*pos); | 1754 | reason_code = le16_to_cpu(*pos); |
1737 | 1755 | ||
1738 | PDEBUG(DEBUG_AP, "%s: deauthentication: %s len=%d, " | 1756 | PDEBUG(DEBUG_AP, "%s: deauthentication: " MAC_FMT " len=%d, " |
1739 | "reason_code=%d\n", dev->name, print_mac(mac, hdr->addr2), len, | 1757 | "reason_code=%d\n", dev->name, |
1740 | reason_code); | 1758 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], |
1759 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5], | ||
1760 | len, reason_code); | ||
1741 | 1761 | ||
1742 | spin_lock_bh(&local->ap->sta_table_lock); | 1762 | spin_lock_bh(&local->ap->sta_table_lock); |
1743 | sta = ap_get_sta(local->ap, hdr->addr2); | 1763 | sta = ap_get_sta(local->ap, hdr->addr2); |
@@ -1748,9 +1768,11 @@ static void handle_deauth(local_info_t *local, struct sk_buff *skb, | |||
1748 | } | 1768 | } |
1749 | spin_unlock_bh(&local->ap->sta_table_lock); | 1769 | spin_unlock_bh(&local->ap->sta_table_lock); |
1750 | if (sta == NULL) { | 1770 | if (sta == NULL) { |
1751 | printk("%s: deauthentication from %s, " | 1771 | printk("%s: deauthentication from " MAC_FMT ", " |
1752 | "reason_code=%d, but STA not authenticated\n", dev->name, | 1772 | "reason_code=%d, but STA not authenticated\n", dev->name, |
1753 | print_mac(mac, hdr->addr2), reason_code); | 1773 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], |
1774 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5], | ||
1775 | reason_code); | ||
1754 | } | 1776 | } |
1755 | } | 1777 | } |
1756 | 1778 | ||
@@ -1766,7 +1788,6 @@ static void handle_disassoc(local_info_t *local, struct sk_buff *skb, | |||
1766 | u16 reason_code; | 1788 | u16 reason_code; |
1767 | __le16 *pos; | 1789 | __le16 *pos; |
1768 | struct sta_info *sta = NULL; | 1790 | struct sta_info *sta = NULL; |
1769 | DECLARE_MAC_BUF(mac); | ||
1770 | 1791 | ||
1771 | len = skb->len - IEEE80211_MGMT_HDR_LEN; | 1792 | len = skb->len - IEEE80211_MGMT_HDR_LEN; |
1772 | 1793 | ||
@@ -1778,9 +1799,11 @@ static void handle_disassoc(local_info_t *local, struct sk_buff *skb, | |||
1778 | pos = (__le16 *) body; | 1799 | pos = (__le16 *) body; |
1779 | reason_code = le16_to_cpu(*pos); | 1800 | reason_code = le16_to_cpu(*pos); |
1780 | 1801 | ||
1781 | PDEBUG(DEBUG_AP, "%s: disassociation: %s len=%d, " | 1802 | PDEBUG(DEBUG_AP, "%s: disassociation: " MAC_FMT " len=%d, " |
1782 | "reason_code=%d\n", dev->name, print_mac(mac, hdr->addr2), len, | 1803 | "reason_code=%d\n", dev->name, |
1783 | reason_code); | 1804 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], |
1805 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5], | ||
1806 | len, reason_code); | ||
1784 | 1807 | ||
1785 | spin_lock_bh(&local->ap->sta_table_lock); | 1808 | spin_lock_bh(&local->ap->sta_table_lock); |
1786 | sta = ap_get_sta(local->ap, hdr->addr2); | 1809 | sta = ap_get_sta(local->ap, hdr->addr2); |
@@ -1791,9 +1814,12 @@ static void handle_disassoc(local_info_t *local, struct sk_buff *skb, | |||
1791 | } | 1814 | } |
1792 | spin_unlock_bh(&local->ap->sta_table_lock); | 1815 | spin_unlock_bh(&local->ap->sta_table_lock); |
1793 | if (sta == NULL) { | 1816 | if (sta == NULL) { |
1794 | printk("%s: disassociation from %s, " | 1817 | printk("%s: disassociation from " MAC_FMT ", " |
1795 | "reason_code=%d, but STA not authenticated\n", | 1818 | "reason_code=%d, but STA not authenticated\n", |
1796 | dev->name, print_mac(mac, hdr->addr2), reason_code); | 1819 | dev->name, |
1820 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], | ||
1821 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5], | ||
1822 | reason_code); | ||
1797 | } | 1823 | } |
1798 | } | 1824 | } |
1799 | 1825 | ||
@@ -1882,16 +1908,20 @@ static void handle_pspoll(local_info_t *local, | |||
1882 | struct sta_info *sta; | 1908 | struct sta_info *sta; |
1883 | u16 aid; | 1909 | u16 aid; |
1884 | struct sk_buff *skb; | 1910 | struct sk_buff *skb; |
1885 | DECLARE_MAC_BUF(mac); | ||
1886 | 1911 | ||
1887 | PDEBUG(DEBUG_PS2, "handle_pspoll: BSSID=%s" | 1912 | PDEBUG(DEBUG_PS2, "handle_pspoll: BSSID=" MAC_FMT |
1888 | ", TA=%s PWRMGT=%d\n", | 1913 | ", TA=" MAC_FMT " PWRMGT=%d\n", |
1889 | print_mac(mac, hdr->addr1), print_mac(mac, hdr->addr2), | 1914 | hdr->addr1[0], hdr->addr1[1], hdr->addr1[2], |
1915 | hdr->addr1[3], hdr->addr1[4], hdr->addr1[5], | ||
1916 | hdr->addr2[0], hdr->addr2[1], hdr->addr2[2], | ||
1917 | hdr->addr2[3], hdr->addr2[4], hdr->addr2[5], | ||
1890 | !!(le16_to_cpu(hdr->frame_ctl) & IEEE80211_FCTL_PM)); | 1918 | !!(le16_to_cpu(hdr->frame_ctl) & IEEE80211_FCTL_PM)); |
1891 | 1919 | ||
1892 | if (memcmp(hdr->addr1, dev->dev_addr, ETH_ALEN)) { | 1920 | if (memcmp(hdr->addr1, dev->dev_addr, ETH_ALEN)) { |
1893 | PDEBUG(DEBUG_AP, "handle_pspoll - addr1(BSSID)=%s" | 1921 | PDEBUG(DEBUG_AP, "handle_pspoll - addr1(BSSID)=" MAC_FMT |
1894 | " not own MAC\n", print_mac(mac, hdr->addr1)); | 1922 | " not own MAC\n", |
1923 | hdr->addr1[0], hdr->addr1[1], hdr->addr1[2], | ||
1924 | hdr->addr1[3], hdr->addr1[4], hdr->addr1[5]); | ||
1895 | return; | 1925 | return; |
1896 | } | 1926 | } |
1897 | 1927 | ||
@@ -1969,7 +1999,6 @@ static void handle_wds_oper_queue(struct work_struct *work) | |||
1969 | wds_oper_queue); | 1999 | wds_oper_queue); |
1970 | local_info_t *local = ap->local; | 2000 | local_info_t *local = ap->local; |
1971 | struct wds_oper_data *entry, *prev; | 2001 | struct wds_oper_data *entry, *prev; |
1972 | DECLARE_MAC_BUF(mac); | ||
1973 | 2002 | ||
1974 | spin_lock_bh(&local->lock); | 2003 | spin_lock_bh(&local->lock); |
1975 | entry = local->ap->wds_oper_entries; | 2004 | entry = local->ap->wds_oper_entries; |
@@ -1978,10 +2007,11 @@ static void handle_wds_oper_queue(struct work_struct *work) | |||
1978 | 2007 | ||
1979 | while (entry) { | 2008 | while (entry) { |
1980 | PDEBUG(DEBUG_AP, "%s: %s automatic WDS connection " | 2009 | PDEBUG(DEBUG_AP, "%s: %s automatic WDS connection " |
1981 | "to AP %s\n", | 2010 | "to AP " MAC_FMT "\n", |
1982 | local->dev->name, | 2011 | local->dev->name, |
1983 | entry->type == WDS_ADD ? "adding" : "removing", | 2012 | entry->type == WDS_ADD ? "adding" : "removing", |
1984 | print_mac(mac, entry->addr)); | 2013 | entry->addr[0], entry->addr[1], entry->addr[2], |
2014 | entry->addr[3], entry->addr[4], entry->addr[5]); | ||
1985 | if (entry->type == WDS_ADD) | 2015 | if (entry->type == WDS_ADD) |
1986 | prism2_wds_add(local, entry->addr, 0); | 2016 | prism2_wds_add(local, entry->addr, 0); |
1987 | else if (entry->type == WDS_DEL) | 2017 | else if (entry->type == WDS_DEL) |
@@ -2158,7 +2188,6 @@ static void handle_ap_item(local_info_t *local, struct sk_buff *skb, | |||
2158 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ | 2188 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ |
2159 | u16 fc, type, stype; | 2189 | u16 fc, type, stype; |
2160 | struct ieee80211_hdr_4addr *hdr; | 2190 | struct ieee80211_hdr_4addr *hdr; |
2161 | DECLARE_MAC_BUF(mac); | ||
2162 | 2191 | ||
2163 | /* FIX: should give skb->len to handler functions and check that the | 2192 | /* FIX: should give skb->len to handler functions and check that the |
2164 | * buffer is long enough */ | 2193 | * buffer is long enough */ |
@@ -2187,8 +2216,9 @@ static void handle_ap_item(local_info_t *local, struct sk_buff *skb, | |||
2187 | 2216 | ||
2188 | if (memcmp(hdr->addr1, dev->dev_addr, ETH_ALEN)) { | 2217 | if (memcmp(hdr->addr1, dev->dev_addr, ETH_ALEN)) { |
2189 | PDEBUG(DEBUG_AP, "handle_ap_item - addr1(BSSID)=" | 2218 | PDEBUG(DEBUG_AP, "handle_ap_item - addr1(BSSID)=" |
2190 | "%s not own MAC\n", | 2219 | MAC_FMT " not own MAC\n", |
2191 | print_mac(mac, hdr->addr1)); | 2220 | hdr->addr1[0], hdr->addr1[1], hdr->addr1[2], |
2221 | hdr->addr1[3], hdr->addr1[4], hdr->addr1[5]); | ||
2192 | goto done; | 2222 | goto done; |
2193 | } | 2223 | } |
2194 | 2224 | ||
@@ -2224,14 +2254,18 @@ static void handle_ap_item(local_info_t *local, struct sk_buff *skb, | |||
2224 | } | 2254 | } |
2225 | 2255 | ||
2226 | if (memcmp(hdr->addr1, dev->dev_addr, ETH_ALEN)) { | 2256 | if (memcmp(hdr->addr1, dev->dev_addr, ETH_ALEN)) { |
2227 | PDEBUG(DEBUG_AP, "handle_ap_item - addr1(DA)=%s" | 2257 | PDEBUG(DEBUG_AP, "handle_ap_item - addr1(DA)=" MAC_FMT |
2228 | " not own MAC\n", print_mac(mac, hdr->addr1)); | 2258 | " not own MAC\n", |
2259 | hdr->addr1[0], hdr->addr1[1], hdr->addr1[2], | ||
2260 | hdr->addr1[3], hdr->addr1[4], hdr->addr1[5]); | ||
2229 | goto done; | 2261 | goto done; |
2230 | } | 2262 | } |
2231 | 2263 | ||
2232 | if (memcmp(hdr->addr3, dev->dev_addr, ETH_ALEN)) { | 2264 | if (memcmp(hdr->addr3, dev->dev_addr, ETH_ALEN)) { |
2233 | PDEBUG(DEBUG_AP, "handle_ap_item - addr3(BSSID)=%s" | 2265 | PDEBUG(DEBUG_AP, "handle_ap_item - addr3(BSSID)=" MAC_FMT |
2234 | " not own MAC\n", print_mac(mac, hdr->addr3)); | 2266 | " not own MAC\n", |
2267 | hdr->addr3[0], hdr->addr3[1], hdr->addr3[2], | ||
2268 | hdr->addr3[3], hdr->addr3[4], hdr->addr3[5]); | ||
2235 | goto done; | 2269 | goto done; |
2236 | } | 2270 | } |
2237 | 2271 | ||
@@ -2312,7 +2346,6 @@ static void schedule_packet_send(local_info_t *local, struct sta_info *sta) | |||
2312 | struct sk_buff *skb; | 2346 | struct sk_buff *skb; |
2313 | struct ieee80211_hdr_4addr *hdr; | 2347 | struct ieee80211_hdr_4addr *hdr; |
2314 | struct hostap_80211_rx_status rx_stats; | 2348 | struct hostap_80211_rx_status rx_stats; |
2315 | DECLARE_MAC_BUF(mac); | ||
2316 | 2349 | ||
2317 | if (skb_queue_empty(&sta->tx_buf)) | 2350 | if (skb_queue_empty(&sta->tx_buf)) |
2318 | return; | 2351 | return; |
@@ -2334,7 +2367,9 @@ static void schedule_packet_send(local_info_t *local, struct sta_info *sta) | |||
2334 | hdr->duration_id = cpu_to_le16(sta->aid | BIT(15) | BIT(14)); | 2367 | hdr->duration_id = cpu_to_le16(sta->aid | BIT(15) | BIT(14)); |
2335 | 2368 | ||
2336 | PDEBUG(DEBUG_PS2, "%s: Scheduling buffered packet delivery for STA " | 2369 | PDEBUG(DEBUG_PS2, "%s: Scheduling buffered packet delivery for STA " |
2337 | "%s\n", local->dev->name, print_mac(mac, sta->addr)); | 2370 | MAC_FMT "\n", local->dev->name, |
2371 | sta->addr[0], sta->addr[1], sta->addr[2], | ||
2372 | sta->addr[3], sta->addr[4], sta->addr[5]); | ||
2338 | 2373 | ||
2339 | skb->dev = local->dev; | 2374 | skb->dev = local->dev; |
2340 | 2375 | ||
@@ -2661,7 +2696,6 @@ static int ap_update_sta_tx_rate(struct sta_info *sta, struct net_device *dev) | |||
2661 | int ret = sta->tx_rate; | 2696 | int ret = sta->tx_rate; |
2662 | struct hostap_interface *iface; | 2697 | struct hostap_interface *iface; |
2663 | local_info_t *local; | 2698 | local_info_t *local; |
2664 | DECLARE_MAC_BUF(mac); | ||
2665 | 2699 | ||
2666 | iface = netdev_priv(dev); | 2700 | iface = netdev_priv(dev); |
2667 | local = iface->local; | 2701 | local = iface->local; |
@@ -2689,9 +2723,12 @@ static int ap_update_sta_tx_rate(struct sta_info *sta, struct net_device *dev) | |||
2689 | case 3: sta->tx_rate = 110; break; | 2723 | case 3: sta->tx_rate = 110; break; |
2690 | default: sta->tx_rate = 0; break; | 2724 | default: sta->tx_rate = 0; break; |
2691 | } | 2725 | } |
2692 | PDEBUG(DEBUG_AP, "%s: STA %s" | 2726 | PDEBUG(DEBUG_AP, "%s: STA " MAC_FMT |
2693 | " TX rate raised to %d\n", | 2727 | " TX rate raised to %d\n", |
2694 | dev->name, print_mac(mac, sta->addr), sta->tx_rate); | 2728 | dev->name, |
2729 | sta->addr[0], sta->addr[1], sta->addr[2], | ||
2730 | sta->addr[3], sta->addr[4], sta->addr[5], | ||
2731 | sta->tx_rate); | ||
2695 | } | 2732 | } |
2696 | sta->tx_since_last_failure = 0; | 2733 | sta->tx_since_last_failure = 0; |
2697 | } | 2734 | } |
@@ -2709,7 +2746,6 @@ ap_tx_ret hostap_handle_sta_tx(local_info_t *local, struct hostap_tx_data *tx) | |||
2709 | int set_tim, ret; | 2746 | int set_tim, ret; |
2710 | struct ieee80211_hdr_4addr *hdr; | 2747 | struct ieee80211_hdr_4addr *hdr; |
2711 | struct hostap_skb_tx_data *meta; | 2748 | struct hostap_skb_tx_data *meta; |
2712 | DECLARE_MAC_BUF(mac); | ||
2713 | 2749 | ||
2714 | meta = (struct hostap_skb_tx_data *) skb->cb; | 2750 | meta = (struct hostap_skb_tx_data *) skb->cb; |
2715 | ret = AP_TX_CONTINUE; | 2751 | ret = AP_TX_CONTINUE; |
@@ -2745,8 +2781,9 @@ ap_tx_ret hostap_handle_sta_tx(local_info_t *local, struct hostap_tx_data *tx) | |||
2745 | * print out any errors here. */ | 2781 | * print out any errors here. */ |
2746 | if (net_ratelimit()) { | 2782 | if (net_ratelimit()) { |
2747 | printk(KERN_DEBUG "AP: drop packet to non-associated " | 2783 | printk(KERN_DEBUG "AP: drop packet to non-associated " |
2748 | "STA %s\n", | 2784 | "STA " MAC_FMT "\n", |
2749 | print_mac(mac, hdr->addr1)); | 2785 | hdr->addr1[0], hdr->addr1[1], hdr->addr1[2], |
2786 | hdr->addr1[3], hdr->addr1[4], hdr->addr1[5]); | ||
2750 | } | 2787 | } |
2751 | #endif | 2788 | #endif |
2752 | local->ap->tx_drop_nonassoc++; | 2789 | local->ap->tx_drop_nonassoc++; |
@@ -2784,9 +2821,11 @@ ap_tx_ret hostap_handle_sta_tx(local_info_t *local, struct hostap_tx_data *tx) | |||
2784 | } | 2821 | } |
2785 | 2822 | ||
2786 | if (skb_queue_len(&sta->tx_buf) >= STA_MAX_TX_BUFFER) { | 2823 | if (skb_queue_len(&sta->tx_buf) >= STA_MAX_TX_BUFFER) { |
2787 | PDEBUG(DEBUG_PS, "%s: No more space in STA (%s" | 2824 | PDEBUG(DEBUG_PS, "%s: No more space in STA (" MAC_FMT |
2788 | ")'s PS mode buffer\n", | 2825 | ")'s PS mode buffer\n", |
2789 | local->dev->name, print_mac(mac, sta->addr)); | 2826 | local->dev->name, |
2827 | sta->addr[0], sta->addr[1], sta->addr[2], | ||
2828 | sta->addr[3], sta->addr[4], sta->addr[5]); | ||
2790 | /* Make sure that TIM is set for the station (it might not be | 2829 | /* Make sure that TIM is set for the station (it might not be |
2791 | * after AP wlan hw reset). */ | 2830 | * after AP wlan hw reset). */ |
2792 | /* FIX: should fix hw reset to restore bits based on STA | 2831 | /* FIX: should fix hw reset to restore bits based on STA |
@@ -2850,7 +2889,6 @@ void hostap_handle_sta_tx_exc(local_info_t *local, struct sk_buff *skb) | |||
2850 | struct sta_info *sta; | 2889 | struct sta_info *sta; |
2851 | struct ieee80211_hdr_4addr *hdr; | 2890 | struct ieee80211_hdr_4addr *hdr; |
2852 | struct hostap_skb_tx_data *meta; | 2891 | struct hostap_skb_tx_data *meta; |
2853 | DECLARE_MAC_BUF(mac); | ||
2854 | 2892 | ||
2855 | hdr = (struct ieee80211_hdr_4addr *) skb->data; | 2893 | hdr = (struct ieee80211_hdr_4addr *) skb->data; |
2856 | meta = (struct hostap_skb_tx_data *) skb->cb; | 2894 | meta = (struct hostap_skb_tx_data *) skb->cb; |
@@ -2859,9 +2897,12 @@ void hostap_handle_sta_tx_exc(local_info_t *local, struct sk_buff *skb) | |||
2859 | sta = ap_get_sta(local->ap, hdr->addr1); | 2897 | sta = ap_get_sta(local->ap, hdr->addr1); |
2860 | if (!sta) { | 2898 | if (!sta) { |
2861 | spin_unlock(&local->ap->sta_table_lock); | 2899 | spin_unlock(&local->ap->sta_table_lock); |
2862 | PDEBUG(DEBUG_AP, "%s: Could not find STA %s" | 2900 | PDEBUG(DEBUG_AP, "%s: Could not find STA " MAC_FMT |
2863 | " for this TX error (@%lu)\n", | 2901 | " for this TX error (@%lu)\n", |
2864 | local->dev->name, print_mac(mac, hdr->addr1), jiffies); | 2902 | local->dev->name, |
2903 | hdr->addr1[0], hdr->addr1[1], hdr->addr1[2], | ||
2904 | hdr->addr1[3], hdr->addr1[4], hdr->addr1[5], | ||
2905 | jiffies); | ||
2865 | return; | 2906 | return; |
2866 | } | 2907 | } |
2867 | 2908 | ||
@@ -2888,9 +2929,11 @@ void hostap_handle_sta_tx_exc(local_info_t *local, struct sk_buff *skb) | |||
2888 | case 3: sta->tx_rate = 110; break; | 2929 | case 3: sta->tx_rate = 110; break; |
2889 | default: sta->tx_rate = 0; break; | 2930 | default: sta->tx_rate = 0; break; |
2890 | } | 2931 | } |
2891 | PDEBUG(DEBUG_AP, "%s: STA %s" | 2932 | PDEBUG(DEBUG_AP, "%s: STA " MAC_FMT |
2892 | " TX rate lowered to %d\n", | 2933 | " TX rate lowered to %d\n", |
2893 | local->dev->name, print_mac(mac, sta->addr), | 2934 | local->dev->name, |
2935 | sta->addr[0], sta->addr[1], sta->addr[2], | ||
2936 | sta->addr[3], sta->addr[4], sta->addr[5], | ||
2894 | sta->tx_rate); | 2937 | sta->tx_rate); |
2895 | } | 2938 | } |
2896 | sta->tx_consecutive_exc = 0; | 2939 | sta->tx_consecutive_exc = 0; |
@@ -2956,7 +2999,6 @@ ap_rx_ret hostap_handle_sta_rx(local_info_t *local, struct net_device *dev, | |||
2956 | struct sta_info *sta; | 2999 | struct sta_info *sta; |
2957 | u16 fc, type, stype; | 3000 | u16 fc, type, stype; |
2958 | struct ieee80211_hdr_4addr *hdr; | 3001 | struct ieee80211_hdr_4addr *hdr; |
2959 | DECLARE_MAC_BUF(mac); | ||
2960 | 3002 | ||
2961 | if (local->ap == NULL) | 3003 | if (local->ap == NULL) |
2962 | return AP_RX_CONTINUE; | 3004 | return AP_RX_CONTINUE; |
@@ -2988,9 +3030,12 @@ ap_rx_ret hostap_handle_sta_rx(local_info_t *local, struct net_device *dev, | |||
2988 | } else { | 3030 | } else { |
2989 | printk(KERN_DEBUG "%s: dropped received packet" | 3031 | printk(KERN_DEBUG "%s: dropped received packet" |
2990 | " from non-associated STA " | 3032 | " from non-associated STA " |
2991 | "%s" | 3033 | MAC_FMT |
2992 | " (type=0x%02x, subtype=0x%02x)\n", | 3034 | " (type=0x%02x, subtype=0x%02x)\n", |
2993 | dev->name, print_mac(mac, hdr->addr2), | 3035 | dev->name, |
3036 | hdr->addr2[0], hdr->addr2[1], | ||
3037 | hdr->addr2[2], hdr->addr2[3], | ||
3038 | hdr->addr2[4], hdr->addr2[5], | ||
2994 | type >> 2, stype >> 4); | 3039 | type >> 2, stype >> 4); |
2995 | hostap_rx(dev, skb, rx_stats); | 3040 | hostap_rx(dev, skb, rx_stats); |
2996 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ | 3041 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ |
@@ -3025,8 +3070,11 @@ ap_rx_ret hostap_handle_sta_rx(local_info_t *local, struct net_device *dev, | |||
3025 | * being associated. */ | 3070 | * being associated. */ |
3026 | printk(KERN_DEBUG "%s: rejected received nullfunc " | 3071 | printk(KERN_DEBUG "%s: rejected received nullfunc " |
3027 | "frame without ToDS from not associated STA " | 3072 | "frame without ToDS from not associated STA " |
3028 | "%s\n", | 3073 | MAC_FMT "\n", |
3029 | dev->name, print_mac(mac, hdr->addr2)); | 3074 | dev->name, |
3075 | hdr->addr2[0], hdr->addr2[1], | ||
3076 | hdr->addr2[2], hdr->addr2[3], | ||
3077 | hdr->addr2[4], hdr->addr2[5]); | ||
3030 | hostap_rx(dev, skb, rx_stats); | 3078 | hostap_rx(dev, skb, rx_stats); |
3031 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ | 3079 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ |
3032 | } | 3080 | } |
@@ -3043,9 +3091,12 @@ ap_rx_ret hostap_handle_sta_rx(local_info_t *local, struct net_device *dev, | |||
3043 | * If BSSID is own, report the dropping of this frame. */ | 3091 | * If BSSID is own, report the dropping of this frame. */ |
3044 | if (memcmp(hdr->addr3, dev->dev_addr, ETH_ALEN) == 0) { | 3092 | if (memcmp(hdr->addr3, dev->dev_addr, ETH_ALEN) == 0) { |
3045 | printk(KERN_DEBUG "%s: dropped received packet from " | 3093 | printk(KERN_DEBUG "%s: dropped received packet from " |
3046 | "%s with no ToDS flag " | 3094 | MAC_FMT " with no ToDS flag " |
3047 | "(type=0x%02x, subtype=0x%02x)\n", dev->name, | 3095 | "(type=0x%02x, subtype=0x%02x)\n", dev->name, |
3048 | print_mac(mac, hdr->addr2), type >> 2, stype >> 4); | 3096 | hdr->addr2[0], hdr->addr2[1], |
3097 | hdr->addr2[2], hdr->addr2[3], | ||
3098 | hdr->addr2[4], hdr->addr2[5], | ||
3099 | type >> 2, stype >> 4); | ||
3049 | hostap_dump_rx_80211(dev->name, skb, rx_stats); | 3100 | hostap_dump_rx_80211(dev->name, skb, rx_stats); |
3050 | } | 3101 | } |
3051 | ret = AP_RX_DROP; | 3102 | ret = AP_RX_DROP; |
diff --git a/drivers/net/wireless/ipw2200.c b/drivers/net/wireless/ipw2200.c index a56d9fc6354f..98d6ff69d375 100644 --- a/drivers/net/wireless/ipw2200.c +++ b/drivers/net/wireless/ipw2200.c | |||
@@ -10192,7 +10192,6 @@ static int ipw_tx_skb(struct ipw_priv *priv, struct ieee80211_txb *txb, | |||
10192 | u8 id, hdr_len, unicast; | 10192 | u8 id, hdr_len, unicast; |
10193 | u16 remaining_bytes; | 10193 | u16 remaining_bytes; |
10194 | int fc; | 10194 | int fc; |
10195 | DECLARE_MAC_BUF(mac); | ||
10196 | 10195 | ||
10197 | hdr_len = ieee80211_get_hdrlen(le16_to_cpu(hdr->frame_ctl)); | 10196 | hdr_len = ieee80211_get_hdrlen(le16_to_cpu(hdr->frame_ctl)); |
10198 | switch (priv->ieee->iw_mode) { | 10197 | switch (priv->ieee->iw_mode) { |
@@ -10203,8 +10202,10 @@ static int ipw_tx_skb(struct ipw_priv *priv, struct ieee80211_txb *txb, | |||
10203 | id = ipw_add_station(priv, hdr->addr1); | 10202 | id = ipw_add_station(priv, hdr->addr1); |
10204 | if (id == IPW_INVALID_STATION) { | 10203 | if (id == IPW_INVALID_STATION) { |
10205 | IPW_WARNING("Attempt to send data to " | 10204 | IPW_WARNING("Attempt to send data to " |
10206 | "invalid cell: %s\n", | 10205 | "invalid cell: " MAC_FMT "\n", |
10207 | print_mac(mac, hdr->addr1)); | 10206 | hdr->addr1[0], hdr->addr1[1], |
10207 | hdr->addr1[2], hdr->addr1[3], | ||
10208 | hdr->addr1[4], hdr->addr1[5]); | ||
10208 | goto drop; | 10209 | goto drop; |
10209 | } | 10210 | } |
10210 | } | 10211 | } |
@@ -11576,6 +11577,7 @@ static int ipw_prom_alloc(struct ipw_priv *priv) | |||
11576 | priv->prom_priv->priv = priv; | 11577 | priv->prom_priv->priv = priv; |
11577 | 11578 | ||
11578 | strcpy(priv->prom_net_dev->name, "rtap%d"); | 11579 | strcpy(priv->prom_net_dev->name, "rtap%d"); |
11580 | memcpy(priv->prom_net_dev->dev_addr, priv->mac_addr, ETH_ALEN); | ||
11579 | 11581 | ||
11580 | priv->prom_net_dev->type = ARPHRD_IEEE80211_RADIOTAP; | 11582 | priv->prom_net_dev->type = ARPHRD_IEEE80211_RADIOTAP; |
11581 | priv->prom_net_dev->open = ipw_prom_open; | 11583 | priv->prom_net_dev->open = ipw_prom_open; |
diff --git a/drivers/net/wireless/iwlwifi/Kconfig b/drivers/net/wireless/iwlwifi/Kconfig index d1af938b9aa6..b54ff712e703 100644 --- a/drivers/net/wireless/iwlwifi/Kconfig +++ b/drivers/net/wireless/iwlwifi/Kconfig | |||
@@ -20,7 +20,7 @@ config IWL4965 | |||
20 | runs. | 20 | runs. |
21 | 21 | ||
22 | If you want to compile the driver as a module ( = code which can be | 22 | If you want to compile the driver as a module ( = code which can be |
23 | inserted in and remvoed from the running kernel whenever you want), | 23 | inserted in and removed from the running kernel whenever you want), |
24 | say M here and read <file:Documentation/kbuild/modules.txt>. The | 24 | say M here and read <file:Documentation/kbuild/modules.txt>. The |
25 | module will be called iwl4965.ko. | 25 | module will be called iwl4965.ko. |
26 | 26 | ||
@@ -35,7 +35,6 @@ config IWL4965_HT | |||
35 | bool "Enable 802.11n HT features in iwl4965 driver" | 35 | bool "Enable 802.11n HT features in iwl4965 driver" |
36 | depends on EXPERIMENTAL | 36 | depends on EXPERIMENTAL |
37 | depends on IWL4965 && IWL4965_QOS | 37 | depends on IWL4965 && IWL4965_QOS |
38 | depends on n | ||
39 | ---help--- | 38 | ---help--- |
40 | This option enables IEEE 802.11n High Throughput features | 39 | This option enables IEEE 802.11n High Throughput features |
41 | for the iwl4965 driver. | 40 | for the iwl4965 driver. |
@@ -101,7 +100,7 @@ config IWL3945 | |||
101 | runs. | 100 | runs. |
102 | 101 | ||
103 | If you want to compile the driver as a module ( = code which can be | 102 | If you want to compile the driver as a module ( = code which can be |
104 | inserted in and remvoed from the running kernel whenever you want), | 103 | inserted in and removed from the running kernel whenever you want), |
105 | say M here and read <file:Documentation/kbuild/modules.txt>. The | 104 | say M here and read <file:Documentation/kbuild/modules.txt>. The |
106 | module will be called iwl3945.ko. | 105 | module will be called iwl3945.ko. |
107 | 106 | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965.c b/drivers/net/wireless/iwlwifi/iwl-4965.c index d727de8b96fe..65767570be68 100644 --- a/drivers/net/wireless/iwlwifi/iwl-4965.c +++ b/drivers/net/wireless/iwlwifi/iwl-4965.c | |||
@@ -4589,7 +4589,7 @@ static u8 iwl4965_is_fat_tx_allowed(struct iwl4965_priv *priv, | |||
4589 | 4589 | ||
4590 | if (sta_ht_inf) { | 4590 | if (sta_ht_inf) { |
4591 | if ((!sta_ht_inf->ht_supported) || | 4591 | if ((!sta_ht_inf->ht_supported) || |
4592 | (!sta_ht_inf->cap & IEEE80211_HT_CAP_SUP_WIDTH)) | 4592 | (!(sta_ht_inf->cap & IEEE80211_HT_CAP_SUP_WIDTH))) |
4593 | return 0; | 4593 | return 0; |
4594 | } | 4594 | } |
4595 | 4595 | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c index 40b71bc2c4a4..cbaeaf186494 100644 --- a/drivers/net/wireless/iwlwifi/iwl3945-base.c +++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c | |||
@@ -6206,11 +6206,11 @@ static void iwl3945_alive_start(struct iwl3945_priv *priv) | |||
6206 | 6206 | ||
6207 | /* At this point, the NIC is initialized and operational */ | 6207 | /* At this point, the NIC is initialized and operational */ |
6208 | priv->notif_missed_beacons = 0; | 6208 | priv->notif_missed_beacons = 0; |
6209 | set_bit(STATUS_READY, &priv->status); | ||
6210 | 6209 | ||
6211 | iwl3945_reg_txpower_periodic(priv); | 6210 | iwl3945_reg_txpower_periodic(priv); |
6212 | 6211 | ||
6213 | IWL_DEBUG_INFO("ALIVE processing complete.\n"); | 6212 | IWL_DEBUG_INFO("ALIVE processing complete.\n"); |
6213 | set_bit(STATUS_READY, &priv->status); | ||
6214 | wake_up_interruptible(&priv->wait_command_queue); | 6214 | wake_up_interruptible(&priv->wait_command_queue); |
6215 | 6215 | ||
6216 | if (priv->error_recovering) | 6216 | if (priv->error_recovering) |
@@ -8706,7 +8706,7 @@ static int iwl3945_pci_probe(struct pci_dev *pdev, const struct pci_device_id *e | |||
8706 | return err; | 8706 | return err; |
8707 | } | 8707 | } |
8708 | 8708 | ||
8709 | static void iwl3945_pci_remove(struct pci_dev *pdev) | 8709 | static void __devexit iwl3945_pci_remove(struct pci_dev *pdev) |
8710 | { | 8710 | { |
8711 | struct iwl3945_priv *priv = pci_get_drvdata(pdev); | 8711 | struct iwl3945_priv *priv = pci_get_drvdata(pdev); |
8712 | struct list_head *p, *q; | 8712 | struct list_head *p, *q; |
diff --git a/drivers/net/wireless/iwlwifi/iwl4965-base.c b/drivers/net/wireless/iwlwifi/iwl4965-base.c index a23d4798653b..60ec29eab85a 100644 --- a/drivers/net/wireless/iwlwifi/iwl4965-base.c +++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c | |||
@@ -6628,11 +6628,11 @@ static void iwl4965_alive_start(struct iwl4965_priv *priv) | |||
6628 | 6628 | ||
6629 | /* At this point, the NIC is initialized and operational */ | 6629 | /* At this point, the NIC is initialized and operational */ |
6630 | priv->notif_missed_beacons = 0; | 6630 | priv->notif_missed_beacons = 0; |
6631 | set_bit(STATUS_READY, &priv->status); | ||
6632 | 6631 | ||
6633 | iwl4965_rf_kill_ct_config(priv); | 6632 | iwl4965_rf_kill_ct_config(priv); |
6634 | 6633 | ||
6635 | IWL_DEBUG_INFO("ALIVE processing complete.\n"); | 6634 | IWL_DEBUG_INFO("ALIVE processing complete.\n"); |
6635 | set_bit(STATUS_READY, &priv->status); | ||
6636 | wake_up_interruptible(&priv->wait_command_queue); | 6636 | wake_up_interruptible(&priv->wait_command_queue); |
6637 | 6637 | ||
6638 | if (priv->error_recovering) | 6638 | if (priv->error_recovering) |
@@ -9282,7 +9282,7 @@ static int iwl4965_pci_probe(struct pci_dev *pdev, const struct pci_device_id *e | |||
9282 | return err; | 9282 | return err; |
9283 | } | 9283 | } |
9284 | 9284 | ||
9285 | static void iwl4965_pci_remove(struct pci_dev *pdev) | 9285 | static void __devexit iwl4965_pci_remove(struct pci_dev *pdev) |
9286 | { | 9286 | { |
9287 | struct iwl4965_priv *priv = pci_get_drvdata(pdev); | 9287 | struct iwl4965_priv *priv = pci_get_drvdata(pdev); |
9288 | struct list_head *p, *q; | 9288 | struct list_head *p, *q; |
diff --git a/drivers/net/wireless/libertas/assoc.c b/drivers/net/wireless/libertas/assoc.c index 87e145ffe8f1..6a24ed6067e0 100644 --- a/drivers/net/wireless/libertas/assoc.c +++ b/drivers/net/wireless/libertas/assoc.c | |||
@@ -541,7 +541,7 @@ void lbs_association_worker(struct work_struct *work) | |||
541 | } | 541 | } |
542 | 542 | ||
543 | if (find_any_ssid) { | 543 | if (find_any_ssid) { |
544 | u8 new_mode; | 544 | u8 new_mode = assoc_req->mode; |
545 | 545 | ||
546 | ret = lbs_find_best_network_ssid(priv, assoc_req->ssid, | 546 | ret = lbs_find_best_network_ssid(priv, assoc_req->ssid, |
547 | &assoc_req->ssid_len, assoc_req->mode, &new_mode); | 547 | &assoc_req->ssid_len, assoc_req->mode, &new_mode); |
diff --git a/drivers/net/wireless/libertas/if_cs.c b/drivers/net/wireless/libertas/if_cs.c index 5a9cadb97503..038c66a98f15 100644 --- a/drivers/net/wireless/libertas/if_cs.c +++ b/drivers/net/wireless/libertas/if_cs.c | |||
@@ -677,9 +677,7 @@ sbi_get_int_status_exit: | |||
677 | 677 | ||
678 | /* Card has a command result for us */ | 678 | /* Card has a command result for us */ |
679 | if (*ireg & IF_CS_C_S_CMD_UPLD_RDY) { | 679 | if (*ireg & IF_CS_C_S_CMD_UPLD_RDY) { |
680 | spin_lock(&priv->driver_lock); | ||
681 | ret = if_cs_receive_cmdres(priv, priv->upld_buf, &priv->upld_len); | 680 | ret = if_cs_receive_cmdres(priv, priv->upld_buf, &priv->upld_len); |
682 | spin_unlock(&priv->driver_lock); | ||
683 | if (ret < 0) | 681 | if (ret < 0) |
684 | lbs_pr_err("could not receive cmd from card\n"); | 682 | lbs_pr_err("could not receive cmd from card\n"); |
685 | } | 683 | } |
diff --git a/drivers/net/wireless/rt2x00/rt2x00dev.c b/drivers/net/wireless/rt2x00/rt2x00dev.c index bd305f7f3efd..e873a39fcce3 100644 --- a/drivers/net/wireless/rt2x00/rt2x00dev.c +++ b/drivers/net/wireless/rt2x00/rt2x00dev.c | |||
@@ -1393,11 +1393,20 @@ int rt2x00lib_suspend(struct rt2x00_dev *rt2x00dev, pm_message_t state) | |||
1393 | 1393 | ||
1394 | exit: | 1394 | exit: |
1395 | /* | 1395 | /* |
1396 | * Set device mode to sleep for power management. | 1396 | * Set device mode to sleep for power management, |
1397 | * on some hardware this call seems to consistently fail. | ||
1398 | * From the specifications it is hard to tell why it fails, | ||
1399 | * and if this is a "bad thing". | ||
1400 | * Overall it is safe to just ignore the failure and | ||
1401 | * continue suspending. The only downside is that the | ||
1402 | * device will not be in optimal power save mode, but with | ||
1403 | * the radio and the other components already disabled the | ||
1404 | * device is as good as disabled. | ||
1397 | */ | 1405 | */ |
1398 | retval = rt2x00dev->ops->lib->set_device_state(rt2x00dev, STATE_SLEEP); | 1406 | retval = rt2x00dev->ops->lib->set_device_state(rt2x00dev, STATE_SLEEP); |
1399 | if (retval) | 1407 | if (retval) |
1400 | return retval; | 1408 | WARNING(rt2x00dev, "Device failed to enter sleep state, " |
1409 | "continue suspending.\n"); | ||
1401 | 1410 | ||
1402 | return 0; | 1411 | return 0; |
1403 | } | 1412 | } |
diff --git a/drivers/net/wireless/rt2x00/rt61pci.c b/drivers/net/wireless/rt2x00/rt61pci.c index 93ea212fedd5..ad2e7d53b3da 100644 --- a/drivers/net/wireless/rt2x00/rt61pci.c +++ b/drivers/net/wireless/rt2x00/rt61pci.c | |||
@@ -2399,10 +2399,8 @@ static int rt61pci_beacon_update(struct ieee80211_hw *hw, struct sk_buff *skb, | |||
2399 | * beacon frame. | 2399 | * beacon frame. |
2400 | */ | 2400 | */ |
2401 | if (skb_headroom(skb) < TXD_DESC_SIZE) { | 2401 | if (skb_headroom(skb) < TXD_DESC_SIZE) { |
2402 | if (pskb_expand_head(skb, TXD_DESC_SIZE, 0, GFP_ATOMIC)) { | 2402 | if (pskb_expand_head(skb, TXD_DESC_SIZE, 0, GFP_ATOMIC)) |
2403 | dev_kfree_skb(skb); | ||
2404 | return -ENOMEM; | 2403 | return -ENOMEM; |
2405 | } | ||
2406 | } | 2404 | } |
2407 | 2405 | ||
2408 | /* | 2406 | /* |
diff --git a/drivers/net/wireless/rt2x00/rt73usb.c b/drivers/net/wireless/rt2x00/rt73usb.c index 8103d41a1543..3909cf42f472 100644 --- a/drivers/net/wireless/rt2x00/rt73usb.c +++ b/drivers/net/wireless/rt2x00/rt73usb.c | |||
@@ -2095,6 +2095,8 @@ static struct usb_device_id rt73usb_device_table[] = { | |||
2095 | { USB_DEVICE(0x1371, 0x9032), USB_DEVICE_DATA(&rt73usb_ops) }, | 2095 | { USB_DEVICE(0x1371, 0x9032), USB_DEVICE_DATA(&rt73usb_ops) }, |
2096 | /* Conceptronic */ | 2096 | /* Conceptronic */ |
2097 | { USB_DEVICE(0x14b2, 0x3c22), USB_DEVICE_DATA(&rt73usb_ops) }, | 2097 | { USB_DEVICE(0x14b2, 0x3c22), USB_DEVICE_DATA(&rt73usb_ops) }, |
2098 | /* Corega */ | ||
2099 | { USB_DEVICE(0x07aa, 0x002e), USB_DEVICE_DATA(&rt73usb_ops) }, | ||
2098 | /* D-Link */ | 2100 | /* D-Link */ |
2099 | { USB_DEVICE(0x07d1, 0x3c03), USB_DEVICE_DATA(&rt73usb_ops) }, | 2101 | { USB_DEVICE(0x07d1, 0x3c03), USB_DEVICE_DATA(&rt73usb_ops) }, |
2100 | { USB_DEVICE(0x07d1, 0x3c04), USB_DEVICE_DATA(&rt73usb_ops) }, | 2102 | { USB_DEVICE(0x07d1, 0x3c04), USB_DEVICE_DATA(&rt73usb_ops) }, |
diff --git a/drivers/net/wireless/wavelan_cs.h b/drivers/net/wireless/wavelan_cs.h index fabc63ee153c..2e4bfe4147c6 100644 --- a/drivers/net/wireless/wavelan_cs.h +++ b/drivers/net/wireless/wavelan_cs.h | |||
@@ -309,7 +309,7 @@ struct mmw_t | |||
309 | #define MMW_EXT_ANT_INTERNAL 0x00 /* Internal antenna */ | 309 | #define MMW_EXT_ANT_INTERNAL 0x00 /* Internal antenna */ |
310 | #define MMW_EXT_ANT_EXTERNAL 0x03 /* External antenna */ | 310 | #define MMW_EXT_ANT_EXTERNAL 0x03 /* External antenna */ |
311 | #define MMW_EXT_ANT_IQ_TEST 0x1C /* IQ test pattern (set to 0) */ | 311 | #define MMW_EXT_ANT_IQ_TEST 0x1C /* IQ test pattern (set to 0) */ |
312 | }; | 312 | } __attribute__((packed)); |
313 | 313 | ||
314 | /* Size for structure checking (if padding is correct) */ | 314 | /* Size for structure checking (if padding is correct) */ |
315 | #define MMW_SIZE 37 | 315 | #define MMW_SIZE 37 |