[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAM_iQpUK7OiQ0+521W+uoR-O8=BAO5=BU1oNkB7qTd8vo3B57A@mail.gmail.com>
Date: Mon, 30 Jan 2017 21:57:11 -0800
From: Cong Wang <xiyou.wangcong@...il.com>
To: Yotam Gigi <yotamg@...lanox.com>
Cc: Jiri Pirko <jiri@...nulli.us>,
Linux Kernel Network Developers <netdev@...r.kernel.org>,
David Miller <davem@...emloft.net>,
Ido Schimmel <idosch@...lanox.com>,
Elad Raz <eladr@...lanox.com>,
Nogah Frankel <nogahf@...lanox.com>,
Or Gerlitz <ogerlitz@...lanox.com>,
Jamal Hadi Salim <jhs@...atatu.com>,
"geert+renesas@...der.be" <geert+renesas@...der.be>,
Stephen Hemminger <stephen@...workplumber.org>,
Guenter Roeck <linux@...ck-us.net>,
Roopa Prabhu <roopa@...ulusnetworks.com>,
John Fastabend <john.fastabend@...il.com>,
Simon Horman <simon.horman@...ronome.com>,
Roman Mashak <mrv@...atatu.com>
Subject: Re: [patch net-next v2 2/4] net/sched: Introduce sample tc action
On Mon, Jan 30, 2017 at 8:49 AM, Yotam Gigi <yotamg@...lanox.com> wrote:
>
> Cong, after some thinking I think I don't really need the tcf_lock here. I
> don't really care if the truncate, trunc_size, rate and tcf_action are
> consistent among themselves - the only parameter that I care about is the
> psample_group pointer, and it is protected via RCU. As far as I see, there is
> no need to lock here.
OK, I trust you, you should know the logic better than me.
>
> I do need to take the tcf_lock to protect the statistics update in the
> tcf_sample_act code, as far as I see.
>
Hm? You use percpu stats, so you don't need spinlock.
Powered by blists - more mailing lists