Skip to content

Commit

Permalink
mac80211: Ensure enough headroom when forwarding mesh pkt
Browse files Browse the repository at this point in the history
When a buffer is duplicated during MESH packet forwarding,
this patch ensures that the new buffer has enough headroom.

Signed-off-by: Cedric Izoard <cedric.izoard@ceva-dsp.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
  • Loading branch information
Cedric Izoard authored and Johannes Berg committed Dec 13, 2016
1 parent ec4efc4 commit d8da0b5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/mac80211/rx.c
Original file line number Diff line number Diff line change
Expand Up @@ -2472,7 +2472,7 @@ ieee80211_rx_h_mesh_fwding(struct ieee80211_rx_data *rx)
if (!ifmsh->mshcfg.dot11MeshForwarding)
goto out;

fwd_skb = skb_copy(skb, GFP_ATOMIC);
fwd_skb = skb_copy_expand(skb, local->tx_headroom, 0, GFP_ATOMIC);
if (!fwd_skb) {
net_info_ratelimited("%s: failed to clone mesh frame\n",
sdata->name);
Expand Down

0 comments on commit d8da0b5

Please sign in to comment.