diff options
author | Richard Gobert <richardbgobert@gmail.com> | 2022-09-28 14:55:31 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2022-09-30 12:31:46 +0100 |
commit | d427c8999b071af2003203b42a007c4a80156c18 (patch) | |
tree | 60f7796211722aabd9ef73237e93d29c0177dcdb /net/mac80211 | |
parent | 96e0718165a0d36ed4cba365c542818f20bf7640 (diff) |
net-next: skbuff: refactor pskb_pull
pskb_may_pull already contains all of the checks performed by
pskb_pull.
Use pskb_may_pull for validation in pskb_pull, eliminating the
duplication and making __pskb_pull obsolete.
Replace __pskb_pull with pskb_pull where applicable.
Signed-off-by: Richard Gobert <richardbgobert@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/mac80211')
-rw-r--r-- | net/mac80211/rx.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c index 511c809e2c6b..44474889e8e4 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c @@ -49,7 +49,7 @@ static struct sk_buff *ieee80211_clean_skb(struct sk_buff *skb, if (present_fcs_len) __pskb_trim(skb, skb->len - present_fcs_len); - __pskb_pull(skb, rtap_space); + pskb_pull(skb, rtap_space); hdr = (void *)skb->data; fc = hdr->frame_control; @@ -74,7 +74,7 @@ static struct sk_buff *ieee80211_clean_skb(struct sk_buff *skb, memmove(skb->data + IEEE80211_HT_CTL_LEN, skb->data, hdrlen - IEEE80211_HT_CTL_LEN); - __pskb_pull(skb, IEEE80211_HT_CTL_LEN); + pskb_pull(skb, IEEE80211_HT_CTL_LEN); return skb; } |