Skip to content

Commit

Permalink
[NET] IEEE80211: Fix whitespace errors.
Browse files Browse the repository at this point in the history
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
YOSHIFUJI Hideaki authored and David S. Miller committed Feb 11, 2007
1 parent 03d52d7 commit 6426565
Show file tree
Hide file tree
Showing 12 changed files with 145 additions and 145 deletions.
8 changes: 4 additions & 4 deletions net/ieee80211/ieee80211_crypt_wep.c
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ static int prism2_wep_build_iv(struct sk_buff *skb, int hdr_len,
struct prism2_wep_data *wep = priv;
u32 klen, len;
u8 *pos;

if (skb_headroom(skb) < 4 || skb->len < hdr_len)
return -1;

Expand Down Expand Up @@ -146,17 +146,17 @@ static int prism2_wep_encrypt(struct sk_buff *skb, int hdr_len, void *priv)
/* other checks are in prism2_wep_build_iv */
if (skb_tailroom(skb) < 4)
return -1;

/* add the IV to the frame */
if (prism2_wep_build_iv(skb, hdr_len, NULL, 0, priv))
return -1;

/* Copy the IV into the first 3 bytes of the key */
memcpy(key, skb->data + hdr_len, 3);

/* Copy rest of the WEP key (the secret part) */
memcpy(key + 3, wep->key, wep->key_len);

len = skb->len - hdr_len - 4;
pos = skb->data + hdr_len + 4;
klen = 3 + wep->key_len;
Expand Down
6 changes: 3 additions & 3 deletions net/ieee80211/ieee80211_rx.c
Original file line number Diff line number Diff line change
Expand Up @@ -663,7 +663,7 @@ int ieee80211_rx(struct ieee80211_device *ieee, struct sk_buff *skb,
* any security data (IV, ICV, etc) that was left behind */
if (!can_be_decrypted && (fc & IEEE80211_FCTL_PROTECTED) &&
ieee->host_strip_iv_icv) {
int trimlen = 0;
int trimlen = 0;

/* Top two-bits of byte 3 are the key index */
if (skb->len >= hdrlen + 3)
Expand Down Expand Up @@ -852,7 +852,7 @@ void ieee80211_rx_any(struct ieee80211_device *ieee,

if ((fc & IEEE80211_FCTL_VERS) != 0)
goto drop_free;

switch (fc & IEEE80211_FCTL_FTYPE) {
case IEEE80211_FTYPE_MGMT:
if (skb->len < sizeof(struct ieee80211_hdr_3addr))
Expand Down Expand Up @@ -1489,7 +1489,7 @@ static void update_network(struct ieee80211_network *dst,

/* We only update the statistics if they were created by receiving
* the network information on the actual channel the network is on.
*
*
* This keeps beacons received on neighbor channels from bringing
* down the signal level of an AP. */
if (dst->channel == src->stats.received_channel)
Expand Down
6 changes: 3 additions & 3 deletions net/ieee80211/ieee80211_tx.c
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ Desc. | ctrl | dura | DA/RA | TA | SA | Sequ | Frame | fcs |
| | tion | (BSSID) | | | ence | data | |
`--------------------------------------------------| |------'
Total: 28 non-data bytes `----.----'
|
|
.- 'Frame data' expands, if WEP enabled, to <----------'
|
V
Expand All @@ -64,8 +64,8 @@ Bytes | 4 | 0-2296 | 4 |
Desc. | IV | Encrypted | ICV |
| | Packet | |
`-----| |-----'
`-----.-----'
|
`-----.-----'
|
.- 'Encrypted Packet' expands to
|
V
Expand Down
4 changes: 2 additions & 2 deletions net/ieee80211/ieee80211_wx.c
Original file line number Diff line number Diff line change
Expand Up @@ -754,7 +754,7 @@ int ieee80211_wx_set_auth(struct net_device *dev,
int err = 0;

spin_lock_irqsave(&ieee->lock, flags);

switch (wrqu->param.flags & IW_AUTH_INDEX) {
case IW_AUTH_WPA_VERSION:
case IW_AUTH_CIPHER_PAIRWISE:
Expand Down Expand Up @@ -799,7 +799,7 @@ int ieee80211_wx_get_auth(struct net_device *dev,
int err = 0;

spin_lock_irqsave(&ieee->lock, flags);

switch (wrqu->param.flags & IW_AUTH_INDEX) {
case IW_AUTH_WPA_VERSION:
case IW_AUTH_CIPHER_PAIRWISE:
Expand Down
20 changes: 10 additions & 10 deletions net/ieee80211/softmac/ieee80211softmac_assoc.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
* Overview
*
* Before you can associate, you have to authenticate.
*
*
*/

/* Sends out an association request to the desired AP */
Expand All @@ -41,10 +41,10 @@ ieee80211softmac_assoc(struct ieee80211softmac_device *mac, struct ieee80211soft

/* Switch to correct channel for this network */
mac->set_channel(mac->dev, net->channel);

/* Send association request */
ieee80211softmac_send_mgt_frame(mac, net, IEEE80211_STYPE_ASSOC_REQ, 0);

dprintk(KERN_INFO PFX "sent association request!\n");

spin_lock_irqsave(&mac->lock, flags);
Expand Down Expand Up @@ -153,7 +153,7 @@ network_matches_request(struct ieee80211softmac_device *mac, struct ieee80211_ne
}

/* if 'ANY' network requested, take any that doesn't have privacy enabled */
if (mac->associnfo.req_essid.len == 0
if (mac->associnfo.req_essid.len == 0
&& !(net->capability & WLAN_CAPABILITY_PRIVACY))
return 1;
if (net->ssid_len != mac->associnfo.req_essid.len)
Expand Down Expand Up @@ -212,8 +212,8 @@ ieee80211softmac_assoc_work(struct work_struct *work)

/* try to find the requested network in our list, if we found one already */
if (bssvalid || mac->associnfo.bssfixed)
found = ieee80211softmac_get_network_by_bssid(mac, mac->associnfo.bssid);
found = ieee80211softmac_get_network_by_bssid(mac, mac->associnfo.bssid);

/* Search the ieee80211 networks for this network if we didn't find it by bssid,
* but only if we've scanned at least once (to get a better list of networks to
* select from). If we have not scanned before, the !found logic below will be
Expand Down Expand Up @@ -265,7 +265,7 @@ ieee80211softmac_assoc_work(struct work_struct *work)
if (mac->associnfo.scan_retry > 0) {
mac->associnfo.scan_retry--;

/* We know of no such network. Let's scan.
/* We know of no such network. Let's scan.
* NB: this also happens if we had no memory to copy the network info...
* Maybe we can hope to have more memory after scanning finishes ;)
*/
Expand Down Expand Up @@ -353,7 +353,7 @@ ieee80211softmac_associated(struct ieee80211softmac_device *mac,
mac->set_bssid_filter(mac->dev, net->bssid);
memcpy(mac->ieee->bssid, net->bssid, ETH_ALEN);
netif_carrier_on(mac->dev);

mac->association_id = le16_to_cpup(&resp->aid);
}

Expand All @@ -374,7 +374,7 @@ ieee80211softmac_handle_assoc_response(struct net_device * dev,

if (unlikely(!mac->running))
return -ENODEV;

spin_lock_irqsave(&mac->lock, flags);

if (!mac->associnfo.associating) {
Expand Down Expand Up @@ -426,7 +426,7 @@ ieee80211softmac_handle_assoc_response(struct net_device * dev,
mac->associnfo.associated = 0;
ieee80211softmac_call_events_locked(mac, IEEE80211SOFTMAC_EVENT_ASSOCIATE_FAILED, network);
}

spin_unlock_irqrestore(&mac->lock, flags);
return 0;
}
Expand Down
Loading

0 comments on commit 6426565

Please sign in to comment.