projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6297b91
)
mac80211_hwsim: use reset to set mac header
author
Zhang Shengju
<
[email protected]
>
Thu, 3 Mar 2016 01:16:55 +0000
(
01:16
+0000)
committer
David S. Miller
<
[email protected]
>
Sat, 5 Mar 2016 03:45:13 +0000
(22:45 -0500)
Since offset is zero, it's not necessary to use set function. Reset
function is straightforward, and will remove the unnecessary add
operation in set function.
Signed-off-by: Zhang Shengju <
[email protected]
>
Signed-off-by: David S. Miller <
[email protected]
>
drivers/net/wireless/mac80211_hwsim.c
patch
|
blob
|
history
diff --git
a/drivers/net/wireless/mac80211_hwsim.c
b/drivers/net/wireless/mac80211_hwsim.c
index a723a85f5635716aae4afa86cc1d45657f899af0..e85e0737771c87e4b9d445e3fa998d8eb0bbfc28 100644
(file)
--- a/
drivers/net/wireless/mac80211_hwsim.c
+++ b/
drivers/net/wireless/mac80211_hwsim.c
@@
-844,7
+844,7
@@
static void mac80211_hwsim_monitor_rx(struct ieee80211_hw *hw,
hdr->rt_chbitmask = cpu_to_le16(flags);
skb->dev = hwsim_mon;
- skb_
set_mac_header(skb, 0
);
+ skb_
reset_mac_header(skb
);
skb->ip_summed = CHECKSUM_UNNECESSARY;
skb->pkt_type = PACKET_OTHERHOST;
skb->protocol = htons(ETH_P_802_2);
@@
-887,7
+887,7
@@
static void mac80211_hwsim_monitor_ack(struct ieee80211_channel *chan,
memcpy(hdr11->addr1, addr, ETH_ALEN);
skb->dev = hwsim_mon;
- skb_
set_mac_header(skb, 0
);
+ skb_
reset_mac_header(skb
);
skb->ip_summed = CHECKSUM_UNNECESSARY;
skb->pkt_type = PACKET_OTHERHOST;
skb->protocol = htons(ETH_P_802_2);