diff options
author | Daniel Walker <dwalker@mvista.com> | 2007-12-21 23:16:15 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-28 18:09:12 -0500 |
commit | 27ae4d4328769021b95777e37873074c1da52f91 (patch) | |
tree | 288973678d482a731eee32c15abfee9a3b4562e0 /drivers/net/wireless/prism54 | |
parent | 772353d84991ecd2eebc2e287c381cb1626f9209 (diff) |
prism54: remove questionable down_interruptible usage
Reviewing the semaphore usage I noticed these down_interruptible calls. Most
of these aren't returning anything, so a caller can't tell if the operation
completed or not. prism54_wpa_bss_ie_get() returns zero, but it's treated as
the function failing which doesn't seem correct.
Signed-off-by: Daniel Walker <dwalker@mvista.com>
Cc: Michael Wu <flamingice@sourmilk.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/prism54')
-rw-r--r-- | drivers/net/wireless/prism54/isl_ioctl.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/drivers/net/wireless/prism54/isl_ioctl.c b/drivers/net/wireless/prism54/isl_ioctl.c index b9d00730a68d..1b595a6525f4 100644 --- a/drivers/net/wireless/prism54/isl_ioctl.c +++ b/drivers/net/wireless/prism54/isl_ioctl.c | |||
@@ -165,8 +165,7 @@ prism54_update_stats(struct work_struct *work) | |||
165 | struct obj_bss bss, *bss2; | 165 | struct obj_bss bss, *bss2; |
166 | union oid_res_t r; | 166 | union oid_res_t r; |
167 | 167 | ||
168 | if (down_interruptible(&priv->stats_sem)) | 168 | down(&priv->stats_sem); |
169 | return; | ||
170 | 169 | ||
171 | /* Noise floor. | 170 | /* Noise floor. |
172 | * I'm not sure if the unit is dBm. | 171 | * I'm not sure if the unit is dBm. |
@@ -1793,8 +1792,7 @@ prism54_clear_mac(struct islpci_acl *acl) | |||
1793 | struct list_head *ptr, *next; | 1792 | struct list_head *ptr, *next; |
1794 | struct mac_entry *entry; | 1793 | struct mac_entry *entry; |
1795 | 1794 | ||
1796 | if (down_interruptible(&acl->sem)) | 1795 | down(&acl->sem); |
1797 | return; | ||
1798 | 1796 | ||
1799 | if (acl->size == 0) { | 1797 | if (acl->size == 0) { |
1800 | up(&acl->sem); | 1798 | up(&acl->sem); |
@@ -2116,8 +2114,7 @@ prism54_wpa_bss_ie_add(islpci_private *priv, u8 *bssid, | |||
2116 | if (wpa_ie_len > MAX_WPA_IE_LEN) | 2114 | if (wpa_ie_len > MAX_WPA_IE_LEN) |
2117 | wpa_ie_len = MAX_WPA_IE_LEN; | 2115 | wpa_ie_len = MAX_WPA_IE_LEN; |
2118 | 2116 | ||
2119 | if (down_interruptible(&priv->wpa_sem)) | 2117 | down(&priv->wpa_sem); |
2120 | return; | ||
2121 | 2118 | ||
2122 | /* try to use existing entry */ | 2119 | /* try to use existing entry */ |
2123 | list_for_each(ptr, &priv->bss_wpa_list) { | 2120 | list_for_each(ptr, &priv->bss_wpa_list) { |
@@ -2178,8 +2175,7 @@ prism54_wpa_bss_ie_get(islpci_private *priv, u8 *bssid, u8 *wpa_ie) | |||
2178 | struct islpci_bss_wpa_ie *bss = NULL; | 2175 | struct islpci_bss_wpa_ie *bss = NULL; |
2179 | size_t len = 0; | 2176 | size_t len = 0; |
2180 | 2177 | ||
2181 | if (down_interruptible(&priv->wpa_sem)) | 2178 | down(&priv->wpa_sem); |
2182 | return 0; | ||
2183 | 2179 | ||
2184 | list_for_each(ptr, &priv->bss_wpa_list) { | 2180 | list_for_each(ptr, &priv->bss_wpa_list) { |
2185 | bss = list_entry(ptr, struct islpci_bss_wpa_ie, list); | 2181 | bss = list_entry(ptr, struct islpci_bss_wpa_ie, list); |