[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <5428EF64.5030703@gmail.com>
Date: Sun, 28 Sep 2014 22:34:28 -0700
From: John Fastabend <john.fastabend@...il.com>
To: Cong Wang <xiyou.wangcong@...il.com>
CC: Jamal Hadi Salim <jhs@...atatu.com>,
John Fastabend <john.r.fastabend@...el.com>,
netdev <netdev@...r.kernel.org>
Subject: Re: tc rsvp filter show broke
On 09/28/2014 06:40 PM, Cong Wang wrote:
> On Sun, Sep 28, 2014 at 10:50 AM, John Fastabend
> <john.fastabend@...il.com> wrote:
>>
>>
>> I don't think we need this change, (or perhaps it needs to be a bit
>> more complete if something is missing) take a look a
>> tcf_exts_validate(), notice the policer is added to act->list so the
>> if block in dump() work out,
>
> I thought it's clear that act->list is correct here. :)
>
> I was thinking the dump logic was wrong, but you are right that
> it should match the logic in validate. Actually the bug is we forgot
> to copy exts->type, I am going to submit a patch below:
>
> diff --git a/net/sched/cls_api.c b/net/sched/cls_api.c
> index 77147c8..aad6a67 100644
> --- a/net/sched/cls_api.c
> +++ b/net/sched/cls_api.c
> @@ -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
>
Yep it does seem to be missing...
Although with the latest code can we just drop tcf_exts_change()
and call tcf_exts_validate() directly. I'll check in the morning
but a quick glance makes me think it should be OK and simplifies
things.
.John
--
John Fastabend Intel Corporation
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists