]> Git Repo - linux.git/commitdiff
net_sched: copy exts->type in tcf_exts_change()
authorWANG Cong <[email protected]>
Tue, 7 Oct 2014 00:21:54 +0000 (17:21 -0700)
committerDavid S. Miller <[email protected]>
Wed, 8 Oct 2014 19:41:27 +0000 (15:41 -0400)
We need to copy exts->type when committing the change, otherwise
it would be always 0. This is a quick fix for -net and -stable,
for net-next tcf_exts will be removed.

Fixes: commit 33be627159913b094bb578e83 ("net_sched: act: use standard struct list_head")
Reported-by: Jamal Hadi Salim <[email protected]>
Cc: Jamal Hadi Salim <[email protected]>
Cc: John Fastabend <[email protected]>
Signed-off-by: Cong Wang <[email protected]>
Acked-by: Jamal Hadi Salim <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
net/sched/cls_api.c

index c28b0d327b124b8b478680293f145214caa6f835..4f4e08b0e2b70be52f9a38d4449902176a233a64 100644 (file)
@@ -549,6 +549,7 @@ void tcf_exts_change(struct tcf_proto *tp, struct tcf_exts *dst,
        tcf_tree_lock(tp);
        list_splice_init(&dst->actions, &tmp);
        list_splice(&src->actions, &dst->actions);
+       dst->type = src->type;
        tcf_tree_unlock(tp);
        tcf_action_destroy(&tmp, TCA_ACT_UNBIND);
 #endif
This page took 0.044943 seconds and 4 git commands to generate.