OSDN Git Service

net/sched: act_ct: fix restore the qdisc_skb_cb after defrag
authorwenxu <wenxu@ucloud.cn>
Sun, 19 Jul 2020 12:30:37 +0000 (20:30 +0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 21 Jul 2020 01:36:37 +0000 (18:36 -0700)
commitae372cb1750f6c95370f92fe5f5620e0954663ba
tree12e495c274a10e79adf2ec3b2b26f013c472392b
parent1e8fd3a97f2d83a7197876ceb4f37b4c2b00a0f3
net/sched: act_ct: fix restore the qdisc_skb_cb after defrag

The fragment packets do defrag in tcf_ct_handle_fragments
will clear the skb->cb which make the qdisc_skb_cb clear
too. So the qdsic_skb_cb should be store before defrag and
restore after that.
It also update the pkt_len after all the
fragments finish the defrag to one packet and make the
following actions counter correct.

Fixes: b57dc7c13ea9 ("net/sched: Introduce action ct")
Signed-off-by: wenxu <wenxu@ucloud.cn>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sched/act_ct.c