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)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 31 Jul 2020 16:47:14 +0000 (18:47 +0200)
commitfbff97eb6f4a94a3f15f685bed604c9adc29ac3e
treec35e03aaeaa768fa8629dc61f6e21a8ed3cef6f8
parent8480cda9d1d84c5ce18e2a93f9fedae1e63b7ff2
net/sched: act_ct: fix restore the qdisc_skb_cb after defrag

[ Upstream commit ae372cb1750f6c95370f92fe5f5620e0954663ba ]

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>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/sched/act_ct.c