From: Jakub Kicinski <kuba@kernel.org>
To: Mengyuan Lou <mengyuanlou@net-swift.com>
Cc: netdev@vger.kernel.org, jiawenwu@trustnetic.com,
duanqiangwen@net-swift.com, linglingzhang@net-swift.com,
andrew+netdev@lunn.ch, davem@davemloft.net, edumazet@google.com,
pabeni@redhat.com
Subject: Re: [PATCH net-next v5] net: Wangxun: protect ring accesses with RCU
Date: Tue, 15 Sep 2026 18:41:27 -0700 [thread overview]
Message-ID: <20260915184127.25de623e@kernel.org> (raw)
In-Reply-To: <20260909090005.79368-1-mengyuanlou@net-swift.com>
On Wed, 9 Sep 2026 17:00:05 +0800 Mengyuan Lou wrote:
> + struct wx_ring *rx_ring = rcu_dereference_protected(wx->rx_ring[i], 1);
These rcu_dereference_protected( , 1) calls are quite ugly.
Presumably you are expecting safety here because of rtnl lock?
so rtnl_dereference() ?
Otherwise please add a helper like
wx_get_rxq_locked(wx, i)
{
return rcu_dereference_protected(wx->rx_ring[i], ...real cond..);
}
--
pw-bot: cr
prev parent reply other threads:[~2026-09-16 1:41 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-09 9:00 [PATCH net-next v5] net: Wangxun: protect ring accesses with RCU Mengyuan Lou
2026-09-10 10:01 ` netdev-bot+sashiko
2026-09-11 2:41 ` mengyuanlou
2026-09-16 1:41 ` Jakub Kicinski [this message]
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=20260915184127.25de623e@kernel.org \
--to=kuba@kernel.org \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=duanqiangwen@net-swift.com \
--cc=edumazet@google.com \
--cc=jiawenwu@trustnetic.com \
--cc=linglingzhang@net-swift.com \
--cc=mengyuanlou@net-swift.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
/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