From: Namjae Jeon <linkinjeon@kernel.org>
To: linux-cifs@vger.kernel.org
Cc: smfrench@gmail.com, senozhatsky@chromium.org, tom@talpey.com,
atteh.mailbox@gmail.com, Namjae Jeon <linkinjeon@kernel.org>
Subject: [PATCH 5/6] ksmbd: add debug print for pending request during server shutdown
Date: Sat, 23 Nov 2024 13:17:05 +0900 [thread overview]
Message-ID: <20241123041706.4943-5-linkinjeon@kernel.org> (raw)
In-Reply-To: <20241123041706.4943-1-linkinjeon@kernel.org>
We need to know how many pending requests are left at the end of server
shutdown. That means we need to know how long the server will wait
to process pending requests in case of a server shutdown.
Signed-off-by: Namjae Jeon <linkinjeon@kernel.org>
---
fs/smb/server/connection.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/fs/smb/server/connection.c b/fs/smb/server/connection.c
index 23c5ff84c9eb..a329e6c9076e 100644
--- a/fs/smb/server/connection.c
+++ b/fs/smb/server/connection.c
@@ -404,6 +404,7 @@ int ksmbd_conn_handler_loop(void *p)
out:
ksmbd_conn_set_releasing(conn);
/* Wait till all reference dropped to the Server object*/
+ ksmbd_debug(CONN, "Wait for all pending requests(%d)\n", atomic_read(&conn->r_count));
wait_event(conn->r_count_q, atomic_read(&conn->r_count) == 0);
if (IS_ENABLED(CONFIG_UNICODE))
--
2.25.1
next prev parent reply other threads:[~2024-11-23 4:17 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-23 4:17 [PATCH 1/6] ksmbd: use __GFP_RETRY_MAYFAIL Namjae Jeon
2024-11-23 4:17 ` [PATCH 2/6] ksmbd: add debug print for rdma capable Namjae Jeon
2024-11-23 4:17 ` [PATCH 3/6] ksmbd: add debug prints to know what smb2 requests were received Namjae Jeon
2024-11-23 4:17 ` [PATCH 4/6] ksmbd: add netdev-up/down event debug print Namjae Jeon
2024-11-23 4:17 ` Namjae Jeon [this message]
2024-11-23 4:17 ` [PATCH 6/6] ksmbd: use msleep instaed of schedule_timeout_interruptible() Namjae Jeon
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=20241123041706.4943-5-linkinjeon@kernel.org \
--to=linkinjeon@kernel.org \
--cc=atteh.mailbox@gmail.com \
--cc=linux-cifs@vger.kernel.org \
--cc=senozhatsky@chromium.org \
--cc=smfrench@gmail.com \
--cc=tom@talpey.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