linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] fuse: limit debug log output during ring teardown
@ 2025-11-29 11:06 Long Li
  2025-12-02 17:40 ` Bernd Schubert
  0 siblings, 1 reply; 3+ messages in thread
From: Long Li @ 2025-11-29 11:06 UTC (permalink / raw)
  To: miklos; +Cc: linux-fsdevel, bschubert, leo.lilong, yangerkun, lonuxli.64

Currently, if there are pending entries in the queue after the teardown
timeout, the system keeps printing entry state information at very short
intervals (FUSE_URING_TEARDOWN_INTERVAL). This can flood the system logs.
Additionally, ring->stop_debug_log is set but not used.

Use ring->stop_debug_log as a control flag to only print entry state
information once after teardown timeout, preventing excessive debug
output. Also add a final message when all queues have stopped.

Signed-off-by: Long Li <leo.lilong@huawei.com>
---
 fs/fuse/dev_uring.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/fs/fuse/dev_uring.c b/fs/fuse/dev_uring.c
index 5ceb217ced1b..d71ccdf78887 100644
--- a/fs/fuse/dev_uring.c
+++ b/fs/fuse/dev_uring.c
@@ -453,13 +453,15 @@ static void fuse_uring_async_stop_queues(struct work_struct *work)
 	 * If there are still queue references left
 	 */
 	if (atomic_read(&ring->queue_refs) > 0) {
-		if (time_after(jiffies,
+		if (!ring->stop_debug_log && time_after(jiffies,
 			       ring->teardown_time + FUSE_URING_TEARDOWN_TIMEOUT))
 			fuse_uring_log_ent_state(ring);
 
 		schedule_delayed_work(&ring->async_teardown_work,
 				      FUSE_URING_TEARDOWN_INTERVAL);
 	} else {
+		if (ring->stop_debug_log)
+			pr_info("All queues in the ring=%p have stopped\n", ring);
 		wake_up_all(&ring->stop_waitq);
 	}
 }
-- 
2.39.2


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-12-03  1:34 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-29 11:06 [PATCH] fuse: limit debug log output during ring teardown Long Li
2025-12-02 17:40 ` Bernd Schubert
2025-12-03  1:31   ` Long Li

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).