From: "Paul E. McKenney" <paulmck@kernel.org>
To: peterz@infradead.org, jgross@suse.com, vschneid@redhat.com,
yury.norov@gmail.com
Cc: linux-kernel@vger.kernel.org, imran.f.khan@oracle.com,
kernel-team@meta.com, "Paul E . McKenney" <paulmck@kernel.org>
Subject: [PATCH csd-lock 1/2] smp: Reduce logging due to dump_stack of CSD waiters
Date: Mon, 12 Jun 2023 13:50:35 -0700 [thread overview]
Message-ID: <20230612205036.292542-1-paulmck@kernel.org> (raw)
In-Reply-To: <3ee27fe5-cbea-46b6-adb0-48c4dde92b4f@paulmck-laptop>
From: Imran Khan <imran.f.khan@oracle.com>
If a waiter is waiting for CSD lock, its call stack will not change
between first and subsequent hang detection for the same CSD lock.
Therefore, do dump_stack only for first-time detection for a given waiter.
This avoids excessive logging on systems with hundreds of CPUs where
repetitive dump_stack from hundreds of CPUs would otherwise flood the
console.
Signed-off-by: Imran Khan <imran.f.khan@oracle.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Juergen Gross <jgross@suse.com>
Cc: Valentin Schneider <vschneid@redhat.com>
Cc: Yury Norov <yury.norov@gmail.com>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
---
kernel/smp.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/kernel/smp.c b/kernel/smp.c
index ab3e5dad6cfe..b7ccba677a0a 100644
--- a/kernel/smp.c
+++ b/kernel/smp.c
@@ -248,7 +248,8 @@ static bool csd_lock_wait_toolong(struct __call_single_data *csd, u64 ts0, u64 *
arch_send_call_function_single_ipi(cpu);
}
}
- dump_stack();
+ if (firsttime)
+ dump_stack();
*ts1 = ts2;
return false;
--
2.40.1
next prev parent reply other threads:[~2023-06-12 20:57 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-12 20:49 [PATCH csd-lock] Decrease console output from CSD-lock timeouts Paul E. McKenney
2023-06-12 20:50 ` Paul E. McKenney [this message]
2023-06-12 20:50 ` [PATCH csd-lock 2/2] smp: Reduce NMI traffic from CSD waiters to CSD destination Paul E. McKenney
2023-06-25 15:42 ` [PATCH csd-lock] Decrease console output from CSD-lock timeouts Paul E. McKenney
2023-07-17 15:36 ` Paul E. McKenney
2023-07-17 18:35 [PATCH csd-lock] Decrease console output from CSD-lock timeouts for v6.6 Paul E. McKenney
2023-07-17 18:36 ` [PATCH csd-lock 1/2] smp: Reduce logging due to dump_stack of CSD waiters Paul E. McKenney
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=20230612205036.292542-1-paulmck@kernel.org \
--to=paulmck@kernel.org \
--cc=imran.f.khan@oracle.com \
--cc=jgross@suse.com \
--cc=kernel-team@meta.com \
--cc=linux-kernel@vger.kernel.org \
--cc=peterz@infradead.org \
--cc=vschneid@redhat.com \
--cc=yury.norov@gmail.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
all inboxes | Powered by JetHome®