From: netdev-bot+sashiko@kernel.org
To: achender@kernel.org
Cc: netdev@vger.kernel.org, linux-rdma@vger.kernel.org,
pabeni@redhat.com, edumazet@google.com, kuba@kernel.org,
horms@kernel.org
Subject: Re: [PATCH net-next v11 04/12] net/rds: make rds_destroy_pending() report a connection's own destroy
Date: Tue, 10 Nov 2026 13:57:52 +0000 [thread overview]
Message-ID: <179431907250.994134.9563247907146216368@kernel.org> (raw)
In-Reply-To: <20261106031615.1047052-5-achender@kernel.org>
Thank you for your contribution! Sashiko AI review found more severe
issue(s) in other patches of this series. This mail is only an FYI, in case
you want to address the nit picks below when you respin.
Low priority / nit picks for your consideration:
- [Low] The commit message gets the history of RDS_DESTROY_PENDING and
c_destroy_in_prog wrong, and it leaves out that mainline already had a…
--
net/rds: make rds_destroy_pending() report a connection's own destroy
This patch adds a per-connection c_destroy_in_prog flag. The flag is set
in rds_conn_destroy() before the unhash and synchronize_rcu(), and
rds_destroy_pending() tests it first. The patch also drops the unused
RDS_DESTROY_PENDING cp_flags bit and its dead test in rds_ib_is_unloading().
> The cp_flags bit that once served this purpose, RDS_DESTROY_PENDING
> from commit c90ecbfaf50d2 ("rds: Use atomic flag to track connections
> being destroyed"), was only ever set on the IB protocol-version path
> and lost its last set_bit in commit cdc306a5c9cd3 ("rds: make v3.1 as
> compat version"); it never covered the loopback path above, which
> commit c809195f5523 ("rds: clean up loopback rds_connections on netns
> deletion") added.
[Severity: Low]
Is this history accurate? Commit c90ecbfaf50d2 set the bit
unconditionally at the top of rds_conn_path_destroy(). That function
runs on every connection destroy, for every transport:
net/rds/connection.c:rds_conn_path_destroy() {
struct rds_message *rm, *rtmp;
+ set_bit(RDS_DESTROY_PENDING, &cp->cp_flags);
...
}
The same commit also removed a c_destroy_in_prog field from struct
rds_connection. rds_conn_destroy() used to set that field in the same
place where this patch now adds the WRITE_ONCE():
net/rds/connection.c:rds_conn_destroy() {
...
- conn->c_destroy_in_prog = 1;
/* Ensure conn will not be scheduled for reconnect */
spin_lock_irq(&rds_conn_lock);
...
}
Commit ebeeb1ad9b8a ("rds: tcp: use rds_destroy_pending() to synchronize
netns/module teardown and rds connection/workq management") then removed
that generic set_bit and the synchronize_rcu() from
rds_conn_path_destroy(). It moved the checks into rds_destroy_pending(),
defined as !check_net() || t_unloading(). That is the commit that took
away the per-connection coverage.
After ebeeb1ad9b8a, only the IB connect-complete version-mismatch
set_bit remained, and cdc306a5c9cd3 removed it.
Could the commit message say that this patch brings back a
c_destroy_in_prog field that mainline once had? It would also help to
say that the patch partly reverses the consolidation done in
ebeeb1ad9b8a, and that the global predicate stopped being enough once
c809195f5523 made rds_conn_exit() run rds_loop_net_exit() before
rds_loop_exit().
--
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261106031615.1047052-1-achender%40kernel.org
next prev parent reply other threads:[~2026-11-10 13:57 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-06 3:16 [PATCH net-next v11 00/12] net/rds: make connection lifetime reference-counted Allison Henderson
2026-11-06 3:16 ` [PATCH net-next v11 01/12] net/rds: undo conn_alloc() the same way on every __rds_conn_create() exit Allison Henderson
2026-11-06 3:16 ` [PATCH net-next v11 02/12] net/rds: ib: refuse to attach a connection to a device being removed Allison Henderson
2026-11-06 3:16 ` [PATCH net-next v11 03/12] net/rds: guard every work-requeueing site with rds_destroy_pending() Allison Henderson
2026-11-06 3:16 ` [PATCH net-next v11 04/12] net/rds: make rds_destroy_pending() report a connection's own destroy Allison Henderson
2026-11-10 13:57 ` netdev-bot+sashiko [this message]
2026-11-06 3:16 ` [PATCH net-next v11 05/12] net/rds: split connection destroy into quiesce and kref-governed free Allison Henderson
2026-11-06 3:16 ` [PATCH net-next v11 06/12] net/rds: unlink transport nodes before a possibly deferred connection free Allison Henderson
2026-11-06 3:16 ` [PATCH net-next v11 07/12] net/rds: wait for connections to be freed on transport unload Allison Henderson
2026-11-06 3:16 ` [PATCH net-next v11 08/12] net/rds: hold a connection reference from struct rds_incoming Allison Henderson
2026-11-10 13:57 ` netdev-bot+sashiko
2026-11-06 3:16 ` [PATCH net-next v11 09/12] net/rds: take cp_lock to purge cp_send_queue in the quiesce Allison Henderson
2026-11-06 3:16 ` [PATCH net-next v11 10/12] net/rds: hold connection references in lookup, sockets and c_passive Allison Henderson
2026-11-06 3:16 ` [PATCH net-next v11 11/12] net/rds: pin the connection across RDMA-CM event handling Allison Henderson
2026-11-10 13:57 ` netdev-bot+sashiko
2026-11-06 3:16 ` [PATCH net-next v11 12/12] net/rds: drop rds_conn_count in favor of t_conn_count Allison Henderson
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=179431907250.994134.9563247907146216368@kernel.org \
--to=netdev-bot+sashiko@kernel.org \
--cc=achender@kernel.org \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-rdma@vger.kernel.org \
--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