Skip to content

Commit 1914848

Browse files
lunnsimonwunderlich
authored andcommitted
batman-adv: Set skb priority in fragments
BATMAN will set the skb->priority based on the IP precedence or 802.1q tag. However, if it needs to fragment the frame, it currently leaves the fragment skb with the default priority and actually overwrites the priority in the unfragmented frame. Fix this. Signed-off-by: Andrew Lunn <[email protected]> Signed-off-by: Marek Lindner <[email protected]> Signed-off-by: Sven Eckelmann <[email protected]> Signed-off-by: Simon Wunderlich <[email protected]>
1 parent 7db682d commit 1914848

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

net/batman-adv/fragmentation.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@
2727
#include <linux/kernel.h>
2828
#include <linux/lockdep.h>
2929
#include <linux/netdevice.h>
30-
#include <linux/pkt_sched.h>
3130
#include <linux/skbuff.h>
3231
#include <linux/slab.h>
3332
#include <linux/spinlock.h>
@@ -414,7 +413,7 @@ static struct sk_buff *batadv_frag_create(struct sk_buff *skb,
414413
if (!skb_fragment)
415414
goto err;
416415

417-
skb->priority = TC_PRIO_CONTROL;
416+
skb_fragment->priority = skb->priority;
418417

419418
/* Eat the last mtu-bytes of the skb */
420419
skb_reserve(skb_fragment, header_size + ETH_HLEN);

0 commit comments

Comments
 (0)