]> git.itanic.dy.fi Git - linux-stable/commit
sch_cake: Make sure we can write the IP header before changing DSCP bits
authorToke Høiland-Jørgensen <toke@redhat.com>
Thu, 4 Apr 2019 13:01:33 +0000 (15:01 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 4 Apr 2019 17:55:59 +0000 (10:55 -0700)
commitc87b4ecdbe8db27867a7b7f840291cd843406bd7
tree745972ccb1eada0d1672c97b65bbde019890316c
parentb2100cc56fca8c51d28aa42a9f1fbcb2cf351996
sch_cake: Make sure we can write the IP header before changing DSCP bits

There is not actually any guarantee that the IP headers are valid before we
access the DSCP bits of the packets. Fix this using the same approach taken
in sch_dsmark.

Reported-by: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
Signed-off-by: Toke Høiland-Jørgensen <toke@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sched/sch_cake.c