pull request: wireless-2.6 2009-10-28
Subsystems (5)
Dave,
Here is a collection of fixes (mostly (almost-)one-liners) intended for 2.6.32. There are a couple of fixes relating to behavior when an association failes, as well as spelling fixes, simply endian fixes, a MAINTAINERS change...I don't think there is anything controversial here...
Please let me know if there are problems!
Thanks,
John
---
Individual patches are available here:
http://www.kernel.org/pub/linux/kernel/people/linville/wireless-2.6/
---
The following changes since commit 66ed1e5ec1d979e572554643063734a7664261bb:
Eric Dumazet (1):
pktgen: Dont leak kernel memory
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6.git master
Andrey Yurovsky (1):
mac80211: trivial: fix spelling in mesh_hwmp
Bartlomiej Zolnierkiewicz (1):
MAINTAINERS: rt2x00 list is moderated
Benoit PAPILLAULT (1):
rt2x00: Fix crypto in TX frame for rt2800usb
Björn Smedman (1):
mac80211: fix for incorrect sequence number on hostapd injected frames
Holger Schurig (1):
libertas spi: fix sparse errors
Johannes Berg (2):
mac80211: keep auth state when assoc fails
cfg80211: sme: deauthenticate on assoc failure
Larry Finger (1):
b43: Fix Bugzilla #14181 and the bug from the previous 'fix'
Miguel Boton (1):
b43: add 'struct b43_wl' missing declaration
Reinette Chatre (1):
mac80211: fix ibss joining
Roel Kluin (1):
airo: Reorder tests, check bounds before element
MAINTAINERS | 2 +- drivers/net/wireless/airo.c | 5 ++--- drivers/net/wireless/b43/leds.h | 1 + drivers/net/wireless/b43/main.c | 1 - drivers/net/wireless/b43/rfkill.c | 3 ++- drivers/net/wireless/libertas/if_spi.c | 10 +++++----- drivers/net/wireless/rt2x00/rt2800usb.c | 2 +- net/mac80211/ibss.c | 6 ++---- net/mac80211/mesh_hwmp.c | 2 +- net/mac80211/mlme.c | 3 +-- net/mac80211/tx.c | 2 +- net/wireless/core.h | 1 + net/wireless/mlme.c | 9 +++++++++ net/wireless/sme.c | 21 +++++++++++++++++++-- 14 files changed, 46 insertions(+), 22 deletions(-)
MAINTAINERS +1 -1
@@ -4280,7 +4280,7 @@ F: drivers/video/aty/aty128fb.c RALINK RT2X00 WIRELESS LAN DRIVER P: rt2x00 project L: [email protected] -L: [email protected] +L: [email protected] (moderated for non-subscribers) W: http://rt2x00.serialmonkey.com/ S: Maintained T: git git://git.kernel.org/pub/scm/linux/kernel/git/ivd/rt2x00.git
drivers/net/wireless/airo.c +2 -3
@@ -4790,9 +4790,8 @@ static int proc_stats_rid_open( struct inode *inode,static int get_dec_u16 (char *buffer,int *start,int limit ) {u16 value;int valid =0 ; -for ( value =0 ; buffer[*start] >='0' && - buffer[*start] <='9' && - *start < limit; (*start)++ ) { +for (value =0 ; *start < limit && buffer[*start] >='0' && + buffer[*start] <='9' ; (*start)++) { valid =1 ; value *=10 ; value += buffer[*start] -'0' ;
drivers/net/wireless/b43/leds.h +1 -0
@@ -1,6 +1,7 @@#ifndef B43_LEDS_H_ #define B43_LEDS_H_ +struct b43_wl ;struct b43_wldev ;#ifdef CONFIG_B43_LEDS
drivers/net/wireless/b43/main.c +0 -1
@@ -4501,7 +4501,6 @@ static void b43_op_stop(struct ieee80211_hw *hw)cancel_work_sync (&(wl->beacon_update_trigger)); -wiphy_rfkill_stop_polling (hw->wiphy);mutex_lock (&wl->mutex);if (b43_status (dev) >=B43_STAT_STARTED ) { dev =b43_wireless_core_stop (dev);
drivers/net/wireless/b43/rfkill.c +2 -1
@@ -33,7 +33,8 @@ bool b43_is_hw_radio_enabled(struct b43_wldev *dev) & B43_MMIO_RADIO_HWENABLED_HI_MASK))return 1 ; }else { -if (b43_read16 (dev,B43_MMIO_RADIO_HWENABLED_LO ) +if (b43_status (dev) >=B43_STAT_STARTED && +b43_read16 (dev,B43_MMIO_RADIO_HWENABLED_LO ) &B43_MMIO_RADIO_HWENABLED_LO_MASK )return 1 ; }
drivers/net/wireless/libertas/if_spi.c +5 -5
@@ -134,7 +134,7 @@ static void spu_transaction_finish(struct if_spi_card *card)static int spu_write (struct if_spi_card *card,u16 reg,const u8 *buf,int len) {int err =0 ; -u16 reg_out =cpu_to_le16 (reg |IF_SPI_WRITE_OPERATION_MASK ); +__le16 reg_out =cpu_to_le16 (reg |IF_SPI_WRITE_OPERATION_MASK );struct spi_message m;struct spi_transfer reg_trans;struct spi_transfer data_trans;
@@ -166,7 +166,7 @@ static int spu_write(struct if_spi_card *card, u16 reg, const u8 *buf, int len)static inline int spu_write_u16 (struct if_spi_card *card,u16 reg,u16 val) { -u16 buff; +__le16 buff; buff =cpu_to_le16 (val);return spu_write (card, reg, (u8 *)&buff,sizeof (u16));
@@ -188,7 +188,7 @@ static int spu_read(struct if_spi_card *card, u16 reg, u8 *buf, int len) {unsigned int delay;int err =0 ; -u16 reg_out =cpu_to_le16 (reg |IF_SPI_READ_OPERATION_MASK ); +__le16 reg_out =cpu_to_le16 (reg |IF_SPI_READ_OPERATION_MASK );struct spi_message m;struct spi_transfer reg_trans;struct spi_transfer dummy_trans;
@@ -235,7 +235,7 @@ static int spu_read(struct if_spi_card *card, u16 reg, u8 *buf, int len)/* Read 16 bits from an SPI register */ static inline int spu_read_u16 (struct if_spi_card *card,u16 reg,u16 *val) { -u16 buf; +__le16 buf;int ret; ret =spu_read (card, reg, (u8 *)&buf,sizeof (buf));
@@ -248,7 +248,7 @@ static inline int spu_read_u16(struct if_spi_card *card, u16 reg, u16 *val)* The low 16 bits are read first. */ static int spu_read_u32 (struct if_spi_card *card,u16 reg,u32 *val) { -u32 buf; +__le32 buf;int err; err =spu_read (card, reg, (u8 *)&buf,sizeof (buf));
drivers/net/wireless/rt2x00/rt2800usb.c +1 -1
@@ -1994,7 +1994,7 @@ static void rt2800usb_write_tx_desc(struct rt2x00_dev *rt2x00dev,rt2x00_set_field32 (&word,TXWI_W1_BW_WIN_SIZE , txdesc->ba_size);rt2x00_set_field32 (&word,TXWI_W1_WIRELESS_CLI_ID ,test_bit (ENTRY_TXD_ENCRYPT , &txdesc->flags) ? - (skbdesc->entry->entry_idx +1 ) :0xff ); + txdesc->key_idx :0xff );rt2x00_set_field32 (&word,TXWI_W1_MPDU_TOTAL_BYTE_COUNT , skb->len - txdesc->l2pad); rt2x00_set_field32(&word, TXWI_W1_PACKETID,
net/mac80211/ibss.c +2 -4
@@ -538,13 +538,12 @@ static void ieee80211_sta_find_ibss(struct ieee80211_sub_if_data *sdata)WLAN_CAPABILITY_PRIVACY , capability); +if (bss) {#ifdef CONFIG_MAC80211_IBSS_DEBUG -if (bss)printk (KERN_DEBUG " sta_find_ibss: selected %pM current " "%pM\n" , bss->cbss.bssid, ifibss->bssid);#endif /* CONFIG_MAC80211_IBSS_DEBUG */ -if (bss && !memcmp (ifibss->bssid, bss->cbss.bssid,ETH_ALEN )) {printk (KERN_DEBUG "%s: Selected IBSS BSSID %pM" " based on configured SSID\n" , sdata->dev->name, bss->cbss.bssid);
@@ -552,8 +551,7 @@ static void ieee80211_sta_find_ibss(struct ieee80211_sub_if_data *sdata)ieee80211_sta_join_ibss (sdata, bss);ieee80211_rx_bss_put (local, bss);return ; - }else if (bss) -ieee80211_rx_bss_put (local, bss); + }#ifdef CONFIG_MAC80211_IBSS_DEBUG printk (KERN_DEBUG " did not try to join ibss\n" );
net/mac80211/mesh_hwmp.c +1 -1
@@ -259,7 +259,7 @@ static u32 airtime_link_metric_get(struct ieee80211_local *local,* @hwmp_ie: hwmp information element (PREP or PREQ) * * This function updates the path routing information to the originator and the -* transmitter of a HWMP PREQ or PREP fram. +* transmitter of a HWMP PREQ or PREP frame. * * Returns: metric to frame originator or 0 if the frame should not be further * processed
net/mac80211/mlme.c +1 -2
@@ -1457,8 +1457,7 @@ ieee80211_rx_mgmt_assoc_resp(struct ieee80211_sub_if_data *sdata,if (status_code !=WLAN_STATUS_SUCCESS ) {printk (KERN_DEBUG "%s: AP denied association (code=%d)\n" , sdata->dev->name, status_code); -list_del (&wk->list); -kfree (wk); + wk->state =IEEE80211_MGD_STATE_IDLE ;return RX_MGMT_CFG80211_ASSOC ; }
net/mac80211/tx.c +1 -1
@@ -1445,7 +1445,7 @@ static void ieee80211_xmit(struct ieee80211_sub_if_data *sdata,if (tmp_sdata->vif.type !=NL80211_IFTYPE_AP )continue ;if (compare_ether_addr (tmp_sdata->dev->dev_addr, - hdr->addr2)) { + hdr->addr2) ==0 ) {dev_hold (tmp_sdata->dev);dev_put (sdata->dev); sdata = tmp_sdata;
net/wireless/core.h +1 -0
@@ -358,6 +358,7 @@ int cfg80211_mgd_wext_connect(struct cfg80211_registered_device *rdev, struct wireless_dev *wdev);void cfg80211_conn_work (struct work_struct *work); +void cfg80211_sme_failed_assoc (struct wireless_dev *wdev);bool cfg80211_sme_failed_reassoc (struct wireless_dev *wdev);/* internal helpers */
net/wireless/mlme.c +9 -0
@@ -62,6 +62,7 @@ void cfg80211_send_rx_assoc(struct net_device *dev, const u8 *buf, size_t len)u8 *ie = mgmt->u.assoc_resp.variable; int i, ieoffs = offsetof(struct ieee80211_mgmt, u.assoc_resp.variable);struct cfg80211_internal_bss *bss =NULL ; +bool need_connect_result = true;wdev_lock (wdev);
@@ -94,6 +95,14 @@ void cfg80211_send_rx_assoc(struct net_device *dev, const u8 *buf, size_t len) }WARN_ON (!bss); + }else if (wdev->conn) { +cfg80211_sme_failed_assoc (wdev); + need_connect_result = false; +/* +* do not call connect_result() now because the +* sme will schedule work that does it later. +*/ + goto out; }if (!wdev->conn && wdev->sme_state ==CFG80211_SME_IDLE ) {
net/wireless/sme.c +19 -2
@@ -26,6 +26,7 @@ struct cfg80211_conn {CFG80211_CONN_AUTHENTICATING ,CFG80211_CONN_ASSOCIATE_NEXT ,CFG80211_CONN_ASSOCIATING , +CFG80211_CONN_DEAUTH_ASSOC_FAIL , } state;u8 bssid[ETH_ALEN ], prev_bssid[ETH_ALEN ];u8 *ie;
@@ -148,6 +149,12 @@ static int cfg80211_conn_do_work(struct wireless_dev *wdev)NULL ,0 , WLAN_REASON_DEAUTH_LEAVING);return err; +case CFG80211_CONN_DEAUTH_ASSOC_FAIL : +__cfg80211_mlme_deauth (rdev, wdev->netdev, params->bssid, +NULL ,0 , +WLAN_REASON_DEAUTH_LEAVING ); +/* return an error so that we call __cfg80211_connect_result() */ +return -EINVAL ;default :return 0 ; }
@@ -158,6 +165,7 @@ void cfg80211_conn_work(struct work_struct *work)struct cfg80211_registered_device *rdev = container_of(work, struct cfg80211_registered_device, conn_work);struct wireless_dev *wdev; +u8 bssid[ETH_ALEN ];rtnl_lock ();cfg80211_lock_rdev (rdev);
@@ -173,10 +181,10 @@ void cfg80211_conn_work(struct work_struct *work)wdev_unlock (wdev);continue ; } +memcpy (bssid, wdev->conn->params.bssid,ETH_ALEN );if (cfg80211_conn_do_work (wdev))__cfg80211_connect_result ( - wdev->netdev, - wdev->conn->params.bssid, + wdev->netdev, bssid,NULL ,0 ,NULL ,0 ,WLAN_STATUS_UNSPECIFIED_FAILURE , false,NULL );
@@ -337,6 +345,15 @@ bool cfg80211_sme_failed_reassoc(struct wireless_dev *wdev)return true; } +void cfg80211_sme_failed_assoc (struct wireless_dev *wdev) +{ +struct wiphy *wiphy = wdev->wiphy; +struct cfg80211_registered_device *rdev =wiphy_to_dev (wiphy); + + wdev->conn->state =CFG80211_CONN_DEAUTH_ASSOC_FAIL ; +schedule_work (&rdev->conn_work); +} + void __cfg80211_connect_result(struct net_device *dev, const u8 *bssid, const u8 *req_ie, size_t req_ie_len, const u8 *resp_ie, size_t resp_ie_len,
Signature · 6 lines
John W. Linville Someday the world will need a hero, and you [email protected] might be all we have. Be ready. -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
David Miller
maintainerFrom: "John W. Linville" <[email protected]>
Date: Wed, 28 Oct 2009 16:53:46 -0400
Quoted 7 lines
Here is a collection of fixes (mostly (almost-)one-liners) intended for 2.6.32. There are a couple of fixes relating to behavior when an association failes, as well as spelling fixes, simply endian fixes, a
MAINTAINERSchange...I don't think there is anything controversial here...Please let me know if there are problems!
Pulled, thanks a lot John.