[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAM_iQpW5h=UCdhJQ7cKgihsn_NPRi8YjTes6R+TrA5WFfagSNA@mail.gmail.com>
Date: Tue, 11 Aug 2020 17:47:59 -0700
From: Cong Wang <xiyou.wangcong@...il.com>
To: Tonghao Zhang <xiangxia.m.yue@...il.com>
Cc: Joel Fernandes <joel@...lfernandes.org>,
Johan Knöös <jknoos@...gle.com>,
Gregory Rose <gvrose8192@...il.com>,
"Uladzislau Rezki (Sony)" <urezki@...il.com>,
"Paul E . McKenney" <paulmck@...nel.org>, dev@...nvswitch.org,
Linux Kernel Network Developers <netdev@...r.kernel.org>,
rcu <rcu@...r.kernel.org>
Subject: Re: [PATCH] net: openvswitch: introduce common code for flushing flows
On Mon, Aug 10, 2020 at 6:14 PM <xiangxia.m.yue@...il.com> wrote:
>
> From: Tonghao Zhang <xiangxia.m.yue@...il.com>
>
> To avoid some issues, for example RCU usage warning, we should
> flush the flows under ovs_lock. This patch refactors
> table_instance_destroy and introduces table_instance_flow_flush
> which can be invoked by __dp_destroy or ovs_flow_tbl_flush.
>
> Signed-off-by: Tonghao Zhang <xiangxia.m.yue@...il.com>
Please add a Fixes tag here, I think it is probably your memory leak fix
which introduced this issue. And a Reported-by, to give credits to bug
reporters.
Plus one minor issue below:
> -static void table_instance_destroy(struct flow_table *table,
> - struct table_instance *ti,
> - struct table_instance *ufid_ti,
> - bool deferred)
> +/* Must be called with OVS mutex held. */
> +void table_instance_flow_flush(struct flow_table *table,
> + struct table_instance *ti,
> + struct table_instance *ufid_ti)
> {
> int i;
>
> - if (!ti)
> - return;
> -
> - BUG_ON(!ufid_ti);
> if (ti->keep_flows)
> - goto skip_flows;
> + return;
>
> for (i = 0; i < ti->n_buckets; i++) {
> - struct sw_flow *flow;
> struct hlist_head *head = &ti->buckets[i];
> struct hlist_node *n;
> + struct sw_flow *flow;
This is at most a coding style change, please do not mix
coding style changes in bug fixes. You can always push coding
style changes separately when net-next is open.
Thanks.
Powered by blists - more mailing lists