From: Paolo Abeni <pabeni@redhat.com>
To: Adrian Moreno <amorenoz@redhat.com>, netdev@vger.kernel.org
Cc: aconole@redhat.com, Eelco Chaudron <echaudro@redhat.com>,
Ilya Maximets <i.maximets@ovn.org>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Simon Horman <horms@kernel.org>,
"open list:OPENVSWITCH" <dev@openvswitch.org>,
open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH net-next v3 1/2] net: openvswitch: make flow_table an rcu pointer
Date: Thu, 7 May 2026 13:03:45 +0200 [thread overview]
Message-ID: <1cc38ea2-74ac-49f5-97b1-b9404726bdbc@redhat.com> (raw)
In-Reply-To: <20260505084253.998548-2-amorenoz@redhat.com>
On 5/5/26 10:42 AM, Adrian Moreno wrote:
> @@ -752,12 +759,16 @@ static struct genl_family dp_packet_genl_family __ro_after_init = {
> static void get_dp_stats(const struct datapath *dp, struct ovs_dp_stats *stats,
> struct ovs_dp_megaflow_stats *mega_stats)
> {
> + struct flow_table *table = ovsl_dereference(dp->table);
> int i;
>
> memset(mega_stats, 0, sizeof(*mega_stats));
> + memset(stats, 0, sizeof(*stats));
Is this an unrelated bugfix, preventing random values from stack
clobbering the stats? Should it land to a separate fix for net?
> @@ -1501,8 +1537,13 @@ static int ovs_flow_cmd_dump(struct sk_buff *skb, struct netlink_callback *cb)
> rcu_read_unlock();
> return -ENODEV;
> }
> + table = rcu_dereference_ovsl(dp->table);
Possibly:
table = rcu_dereference(dp->table);
would be more accurate
> @@ -518,6 +524,7 @@ void ovs_flow_tbl_destroy(struct flow_table *table)
> call_rcu(&mc->rcu, mask_cache_rcu_cb);
> call_rcu(&ma->rcu, mask_array_rcu_cb);
This is always invoked after a rcu grace period, it would be probably
nice to follow-up, not necessarly in this series, moving the above
call_rcu together with the call_rcu(table). Such statements could be
bundled in a new helper.
/P
next prev parent reply other threads:[~2026-05-07 11:03 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-05 8:42 [PATCH net-next v3 0/2] net: openvswitch: Decouple flow operations from RTNL Adrian Moreno
2026-05-05 8:42 ` [PATCH net-next v3 1/2] net: openvswitch: make flow_table an rcu pointer Adrian Moreno
2026-05-07 11:03 ` Paolo Abeni [this message]
2026-05-05 8:42 ` [PATCH net-next v3 2/2] net: openvswitch: decouple flow_table from ovs_mutex Adrian Moreno
2026-05-07 11:31 ` Paolo Abeni
2026-05-07 14:37 ` David Laight
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1cc38ea2-74ac-49f5-97b1-b9404726bdbc@redhat.com \
--to=pabeni@redhat.com \
--cc=aconole@redhat.com \
--cc=amorenoz@redhat.com \
--cc=davem@davemloft.net \
--cc=dev@openvswitch.org \
--cc=echaudro@redhat.com \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=i.maximets@ovn.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox