diff options
author | Johannes Berg <johannes.berg@intel.com> | 2012-07-13 10:23:07 -0400 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2012-07-31 10:19:51 -0400 |
commit | e83e6541cee0a12bc445b0f4fad5214df5803087 (patch) | |
tree | f236e4e330e7c05ca63b350f43f3a97ff9b3e660 /net/mac80211 | |
parent | 1411af156524ce42c2a7f989320c4484257f3ff5 (diff) |
mac80211: use eth_broadcast_addr
Instead of memset().
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211')
-rw-r--r-- | net/mac80211/cfg.c | 2 | ||||
-rw-r--r-- | net/mac80211/ibss.c | 2 | ||||
-rw-r--r-- | net/mac80211/mesh_pathtbl.c | 2 | ||||
-rw-r--r-- | net/mac80211/tx.c | 6 |
4 files changed, 6 insertions, 6 deletions
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index 5583f5b73dc9..df64b455821d 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c | |||
@@ -950,7 +950,7 @@ static void ieee80211_send_layer2_update(struct sta_info *sta) | |||
950 | /* 802.2 Type 1 Logical Link Control (LLC) Exchange Identifier (XID) | 950 | /* 802.2 Type 1 Logical Link Control (LLC) Exchange Identifier (XID) |
951 | * Update response frame; IEEE Std 802.2-1998, 5.4.1.2.1 */ | 951 | * Update response frame; IEEE Std 802.2-1998, 5.4.1.2.1 */ |
952 | 952 | ||
953 | memset(msg->da, 0xff, ETH_ALEN); | 953 | eth_broadcast_addr(msg->da); |
954 | memcpy(msg->sa, sta->sta.addr, ETH_ALEN); | 954 | memcpy(msg->sa, sta->sta.addr, ETH_ALEN); |
955 | msg->len = htons(6); | 955 | msg->len = htons(6); |
956 | msg->dsap = 0; | 956 | msg->dsap = 0; |
diff --git a/net/mac80211/ibss.c b/net/mac80211/ibss.c index d06208518eae..1ebda2f9e57b 100644 --- a/net/mac80211/ibss.c +++ b/net/mac80211/ibss.c | |||
@@ -109,7 +109,7 @@ static void __ieee80211_sta_join_ibss(struct ieee80211_sub_if_data *sdata, | |||
109 | memset(mgmt, 0, 24 + sizeof(mgmt->u.beacon)); | 109 | memset(mgmt, 0, 24 + sizeof(mgmt->u.beacon)); |
110 | mgmt->frame_control = cpu_to_le16(IEEE80211_FTYPE_MGMT | | 110 | mgmt->frame_control = cpu_to_le16(IEEE80211_FTYPE_MGMT | |
111 | IEEE80211_STYPE_PROBE_RESP); | 111 | IEEE80211_STYPE_PROBE_RESP); |
112 | memset(mgmt->da, 0xff, ETH_ALEN); | 112 | eth_broadcast_addr(mgmt->da); |
113 | memcpy(mgmt->sa, sdata->vif.addr, ETH_ALEN); | 113 | memcpy(mgmt->sa, sdata->vif.addr, ETH_ALEN); |
114 | memcpy(mgmt->bssid, ifibss->bssid, ETH_ALEN); | 114 | memcpy(mgmt->bssid, ifibss->bssid, ETH_ALEN); |
115 | mgmt->u.beacon.beacon_int = cpu_to_le16(beacon_int); | 115 | mgmt->u.beacon.beacon_int = cpu_to_le16(beacon_int); |
diff --git a/net/mac80211/mesh_pathtbl.c b/net/mac80211/mesh_pathtbl.c index 075bc535c601..bec7b281b5ba 100644 --- a/net/mac80211/mesh_pathtbl.c +++ b/net/mac80211/mesh_pathtbl.c | |||
@@ -531,7 +531,7 @@ int mesh_path_add(u8 *dst, struct ieee80211_sub_if_data *sdata) | |||
531 | 531 | ||
532 | read_lock_bh(&pathtbl_resize_lock); | 532 | read_lock_bh(&pathtbl_resize_lock); |
533 | memcpy(new_mpath->dst, dst, ETH_ALEN); | 533 | memcpy(new_mpath->dst, dst, ETH_ALEN); |
534 | memset(new_mpath->rann_snd_addr, 0xff, ETH_ALEN); | 534 | eth_broadcast_addr(new_mpath->rann_snd_addr); |
535 | new_mpath->is_root = false; | 535 | new_mpath->is_root = false; |
536 | new_mpath->sdata = sdata; | 536 | new_mpath->sdata = sdata; |
537 | new_mpath->flags = 0; | 537 | new_mpath->flags = 0; |
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c index 5b81660a35b3..7dbcf293708b 100644 --- a/net/mac80211/tx.c +++ b/net/mac80211/tx.c | |||
@@ -2415,7 +2415,7 @@ struct sk_buff *ieee80211_beacon_get_tim(struct ieee80211_hw *hw, | |||
2415 | memset(mgmt, 0, hdr_len); | 2415 | memset(mgmt, 0, hdr_len); |
2416 | mgmt->frame_control = | 2416 | mgmt->frame_control = |
2417 | cpu_to_le16(IEEE80211_FTYPE_MGMT | IEEE80211_STYPE_BEACON); | 2417 | cpu_to_le16(IEEE80211_FTYPE_MGMT | IEEE80211_STYPE_BEACON); |
2418 | memset(mgmt->da, 0xff, ETH_ALEN); | 2418 | eth_broadcast_addr(mgmt->da); |
2419 | memcpy(mgmt->sa, sdata->vif.addr, ETH_ALEN); | 2419 | memcpy(mgmt->sa, sdata->vif.addr, ETH_ALEN); |
2420 | memcpy(mgmt->bssid, sdata->vif.addr, ETH_ALEN); | 2420 | memcpy(mgmt->bssid, sdata->vif.addr, ETH_ALEN); |
2421 | mgmt->u.beacon.beacon_int = | 2421 | mgmt->u.beacon.beacon_int = |
@@ -2609,9 +2609,9 @@ struct sk_buff *ieee80211_probereq_get(struct ieee80211_hw *hw, | |||
2609 | memset(hdr, 0, sizeof(*hdr)); | 2609 | memset(hdr, 0, sizeof(*hdr)); |
2610 | hdr->frame_control = cpu_to_le16(IEEE80211_FTYPE_MGMT | | 2610 | hdr->frame_control = cpu_to_le16(IEEE80211_FTYPE_MGMT | |
2611 | IEEE80211_STYPE_PROBE_REQ); | 2611 | IEEE80211_STYPE_PROBE_REQ); |
2612 | memset(hdr->addr1, 0xff, ETH_ALEN); | 2612 | eth_broadcast_addr(hdr->addr1); |
2613 | memcpy(hdr->addr2, vif->addr, ETH_ALEN); | 2613 | memcpy(hdr->addr2, vif->addr, ETH_ALEN); |
2614 | memset(hdr->addr3, 0xff, ETH_ALEN); | 2614 | eth_broadcast_addr(hdr->addr3); |
2615 | 2615 | ||
2616 | pos = skb_put(skb, ie_ssid_len); | 2616 | pos = skb_put(skb, ie_ssid_len); |
2617 | *pos++ = WLAN_EID_SSID; | 2617 | *pos++ = WLAN_EID_SSID; |