diff options
author | WANG Cong <xiyou.wangcong@gmail.com> | 2013-12-16 05:15:05 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-12-18 18:52:07 +0100 |
commit | 33be627159913b094bb578e83e9a7fdc66c10208 (patch) | |
tree | 387945e9391082d0b78890b176111a53b8897bf3 /net/sched/cls_tcindex.c | |
parent | net_sched: remove get_stats from tc_action_ops (diff) | |
download | linux-33be627159913b094bb578e83e9a7fdc66c10208.tar.xz linux-33be627159913b094bb578e83e9a7fdc66c10208.zip |
net_sched: act: use standard struct list_head
Currently actions are chained by a singly linked list,
therefore it is a bit hard to add and remove a specific
entry. Convert it to struct list_head so that in the
latter patch we can remove an action without finding
its head.
Cc: Jamal Hadi Salim <jhs@mojatatu.com>
Cc: David S. Miller <davem@davemloft.net>
Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com>
Signed-off-by: Jamal Hadi Salim <jhs@mojatatu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/cls_tcindex.c')
-rw-r--r-- | net/sched/cls_tcindex.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/net/sched/cls_tcindex.c b/net/sched/cls_tcindex.c index b86535a40169..c39bbfc0300a 100644 --- a/net/sched/cls_tcindex.c +++ b/net/sched/cls_tcindex.c @@ -215,11 +215,14 @@ tcindex_set_parms(struct net *net, struct tcf_proto *tp, unsigned long base, memcpy(&cp, p, sizeof(cp)); memset(&new_filter_result, 0, sizeof(new_filter_result)); + tcf_exts_init(&new_filter_result.exts); if (old_r) memcpy(&cr, r, sizeof(cr)); - else + else { memset(&cr, 0, sizeof(cr)); + tcf_exts_init(&cr.exts); + } if (tb[TCA_TCINDEX_HASH]) cp.hash = nla_get_u32(tb[TCA_TCINDEX_HASH]); |