[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAM_iQpVeWn1hTVtcQ_H3Jc-gOe91ej0R0XTaMcLHRjOhFkTbJQ@mail.gmail.com>
Date: Fri, 27 Oct 2017 14:44:15 -0700
From: Cong Wang <xiyou.wangcong@...il.com>
To: Manish Kurup <kurup.manish@...il.com>
Cc: Jamal Hadi Salim <jhs@...atatu.com>, Jiri Pirko <jiri@...nulli.us>,
David Miller <davem@...emloft.net>,
Linux Kernel Network Developers <netdev@...r.kernel.org>,
Alexander Aring <aring@...atatu.com>,
Roman Mashak <mrv@...atatu.com>,
Manish Kurup <manish.kurup@...izon.com>
Subject: Re: [PATCH net-next v2 2/2] net sched act_vlan: VLAN action rewrite
to use RCU lock/unlock and update
On Fri, Oct 27, 2017 at 1:49 PM, Manish Kurup <kurup.manish@...il.com> wrote:
> static inline u32 tcf_vlan_action(const struct tc_action *a)
> {
> - return to_vlan(a)->tcfv_action;
> + u32 tcfv_action;
> +
> + rcu_read_lock();
> + tcfv_action = rcu_dereference(to_vlan(a)->vlan_p)->tcfv_action;
> + rcu_read_unlock();
> +
> + return tcfv_action;
> }
It seems we need rcu_read_lock_bh() rather than just rcu_read_lock()?
If so, same for other tcf_vlan_*() helpers.
Powered by blists - more mailing lists