aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/wl12xx
diff options
context:
space:
mode:
authorKalle Valo <kalle.valo@nokia.com>2010-01-05 13:17:10 -0500
committerJohn W. Linville <linville@tuxdriver.com>2010-01-12 13:51:28 -0500
commit80a112ffe8dbada25f3780ecc4beebf23451d755 (patch)
tree4910a393f12ae6ba45dd99d74c36e3a41c52598a /drivers/net/wireless/wl12xx
parentdc52f0a8e50303eb67ff8856cd8d1b461462ceec (diff)
wl1251: fix sleep related error paths in wl1251_op_bss_info_changed()
In various cases wl1251_op_bss_info_changed() did not call elp_sleep() after an error was noticed. Fix it by using correct goto label. The bug was a theoretical one, in practise it doesn't matter because if commands start returning errors there will be lots of other problems. Signed-off-by: Kalle Valo <kalle.valo@nokia.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/wl12xx')
-rw-r--r--drivers/net/wireless/wl12xx/wl1251_main.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1251_main.c b/drivers/net/wireless/wl12xx/wl1251_main.c
index 4728983b4383..f17ce06b6c24 100644
--- a/drivers/net/wireless/wl12xx/wl1251_main.c
+++ b/drivers/net/wireless/wl12xx/wl1251_main.c
@@ -946,7 +946,7 @@ static void wl1251_op_bss_info_changed(struct ieee80211_hw *hw,
946 skb->data, skb->len); 946 skb->data, skb->len);
947 dev_kfree_skb(skb); 947 dev_kfree_skb(skb);
948 if (ret < 0) 948 if (ret < 0)
949 goto out; 949 goto out_sleep;
950 950
951 if (wl->bss_type != BSS_TYPE_IBSS) { 951 if (wl->bss_type != BSS_TYPE_IBSS) {
952 ret = wl1251_join(wl, wl->bss_type, wl->channel, 952 ret = wl1251_join(wl, wl->bss_type, wl->channel,
@@ -1018,7 +1018,7 @@ static void wl1251_op_bss_info_changed(struct ieee80211_hw *hw,
1018 ret = wl1251_acx_cts_protect(wl, CTSPROTECT_DISABLE); 1018 ret = wl1251_acx_cts_protect(wl, CTSPROTECT_DISABLE);
1019 if (ret < 0) { 1019 if (ret < 0) {
1020 wl1251_warning("Set ctsprotect failed %d", ret); 1020 wl1251_warning("Set ctsprotect failed %d", ret);
1021 goto out; 1021 goto out_sleep;
1022 } 1022 }
1023 } 1023 }
1024 1024
@@ -1029,7 +1029,7 @@ static void wl1251_op_bss_info_changed(struct ieee80211_hw *hw,
1029 1029
1030 if (ret < 0) { 1030 if (ret < 0) {
1031 dev_kfree_skb(beacon); 1031 dev_kfree_skb(beacon);
1032 goto out; 1032 goto out_sleep;
1033 } 1033 }
1034 1034
1035 ret = wl1251_cmd_template_set(wl, CMD_PROBE_RESP, beacon->data, 1035 ret = wl1251_cmd_template_set(wl, CMD_PROBE_RESP, beacon->data,
@@ -1038,13 +1038,13 @@ static void wl1251_op_bss_info_changed(struct ieee80211_hw *hw,
1038 dev_kfree_skb(beacon); 1038 dev_kfree_skb(beacon);
1039 1039
1040 if (ret < 0) 1040 if (ret < 0)
1041 goto out; 1041 goto out_sleep;
1042 1042
1043 ret = wl1251_join(wl, wl->bss_type, wl->beacon_int, 1043 ret = wl1251_join(wl, wl->bss_type, wl->beacon_int,
1044 wl->channel, wl->dtim_period); 1044 wl->channel, wl->dtim_period);
1045 1045
1046 if (ret < 0) 1046 if (ret < 0)
1047 goto out; 1047 goto out_sleep;
1048 } 1048 }
1049 1049
1050out_sleep: 1050out_sleep: