summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/mwifiex/join.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2012-10-10 11:59:54 -0400
committerDavid S. Miller <davem@davemloft.net>2012-10-10 11:59:54 -0400
commit85457685e0e314f6902caaef976b3fd8ef4f51b4 (patch)
treea5610b82fdf0a9f2b315cab37656ab97abf93a38 /drivers/net/wireless/mwifiex/join.c
parent2474542f64432398f503373f53bdf620491bcfa8 (diff)
parentc3e7724b6bc2f25e46c38dbe68f09d71fafeafb8 (diff)
downloadop-kernel-dev-85457685e0e314f6902caaef976b3fd8ef4f51b4.zip
op-kernel-dev-85457685e0e314f6902caaef976b3fd8ef4f51b4.tar.gz
Merge tag 'master-2012-10-08' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless
John W. Linville says: ==================== Here is a batch of fixes intended for 3.7... Amitkumar Karwar provides a couple of mwifiex fixes to correctly report some reason codes for certain connection failures. He also provides a fix to cleanup after a scanning failure. Bing Zhao rounds that out with another mwifiex scanning fix. Daniel Golle gives us a fix for a copy/paste error in rt2x00. Felix Fietkau brings a couple of ath9k fixes related to suspend/resume, and a couple of fixes to prevent memory leaks in ath9k and mac80211. Ronald Wahl sends a carl9170 fix for a sleep in softirq context. Thomas Pedersen reorders some code to prevent drv_get_tsf from being called while holding a spinlock, now that it can sleep. Finally, Wei Yongjun prevents a NULL pointer dereference in the ath5k driver. Please let me know if there are problems! ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/wireless/mwifiex/join.c')
-rw-r--r--drivers/net/wireless/mwifiex/join.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/net/wireless/mwifiex/join.c b/drivers/net/wireless/mwifiex/join.c
index 82e63ce..7b0858a 100644
--- a/drivers/net/wireless/mwifiex/join.c
+++ b/drivers/net/wireless/mwifiex/join.c
@@ -1180,16 +1180,18 @@ int mwifiex_ret_802_11_ad_hoc(struct mwifiex_private *priv,
struct mwifiex_adapter *adapter = priv->adapter;
struct host_cmd_ds_802_11_ad_hoc_result *adhoc_result;
struct mwifiex_bssdescriptor *bss_desc;
+ u16 reason_code;
adhoc_result = &resp->params.adhoc_result;
bss_desc = priv->attempted_bss_desc;
/* Join result code 0 --> SUCCESS */
- if (le16_to_cpu(resp->result)) {
+ reason_code = le16_to_cpu(resp->result);
+ if (reason_code) {
dev_err(priv->adapter->dev, "ADHOC_RESP: failed\n");
if (priv->media_connected)
- mwifiex_reset_connect_state(priv);
+ mwifiex_reset_connect_state(priv, reason_code);
memset(&priv->curr_bss_params.bss_descriptor,
0x00, sizeof(struct mwifiex_bssdescriptor));
OpenPOWER on IntegriCloud