mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Mark Brown <broonie@kernel.org>
To: "Paul E. McKenney" <paulmck@kernel.org>
Cc: Breno Leitao <leitao@debian.org>,
	Chuyi Zhou <zhouchuyi@bytedance.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Linux Next Mailing List <linux-next@vger.kernel.org>,
	Thomas Gleixner <tglx@kernel.org>
Subject: linux-next: manual merge of the paulmck tree with the origin tree
Date: Mon, 24 Aug 2026 13:20:39 +0100	[thread overview]
Message-ID: <aow3F8_WbvDDIm1k@sirena.org.uk> (raw)

[-- Attachment #1: Type: text/plain, Size: 2451 bytes --]

Hi all,

Today's linux-next merge of the paulmck tree got a conflict in:

  kernel/smp.c

between commit:

  b46883305f261 ("smp: Disable preemption explicitly in __csd_lock_wait()")

from the origin tree and commit:

  07230d21630f4 ("locking/csd-lock: Pack csd_lock_wait_toolong() state into a struct")

from the paulmck tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

diff --cc kernel/smp.c
index b696bcc60c08f,9092315c144a9..0000000000000
--- a/kernel/smp.c
+++ b/kernel/smp.c
@@@ -285,19 -298,13 +311,19 @@@ static bool csd_lock_wait_toolong(call_
  		cpux = 0;
  	else
  		cpux = cpu;
 -	cpu_cur_csd = smp_load_acquire(&per_cpu(cur_csd, cpux)); /* Before func and info. */
 +	/*
 +	 * Pairs with smp_store_release() of cur_csd in __csd_lock_record():
 +	 * a non-NULL cur_csd here implies cur_csd_func and cur_csd_info
 +	 * are the matching publication; a NULL value is ordered after any
 +	 * preceding CSD callback/unlock on the remote CPU.
 +	 */
 +	cpu_cur_csd = smp_load_acquire(&per_cpu(cur_csd, cpux));
  	/* How long since this CSD lock was stuck. */
- 	ts_delta = ts2 - ts0;
+ 	ts_delta = ts_now - state->ts_start;
  	pr_alert("csd: %s non-responsive CSD lock (#%d) on CPU#%d, waiting %lld ns for CPU#%02d %pS(%ps).\n",
- 		 firsttime ? "Detected" : "Continued", *bug_id, raw_smp_processor_id(), (s64)ts_delta,
+ 		 firsttime ? "Detected" : "Continued", state->bug_id, raw_smp_processor_id(), (s64)ts_delta,
  		 cpu, csd->func, csd->info);
- 	(*nmessages)++;
+ 	state->nmessages++;
  	if (firsttime)
  		atomic_inc(&n_csd_lock_stuck);
  	/*
@@@ -338,15 -346,11 +365,13 @@@
   */
  static void __csd_lock_wait(call_single_data_t *csd)
  {
- 	unsigned long nmessages = 0;
- 	int bug_id = 0;
- 	u64 ts0, ts1;
+ 	struct csd_wait_state state = {};
  
 +	guard(preempt)();
 +
- 	ts1 = ts0 = ktime_get_mono_fast_ns();
+ 	state.ts_report = state.ts_start = ktime_get_mono_fast_ns();
  	for (;;) {
- 		if (csd_lock_wait_toolong(csd, ts0, &ts1, &bug_id, &nmessages))
+ 		if (csd_lock_wait_toolong(csd, &state))
  			break;
  		cpu_relax();
  	}

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

                 reply	other threads:[~2026-08-24 12:20 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=aow3F8_WbvDDIm1k@sirena.org.uk \
    --to=broonie@kernel.org \
    --cc=leitao@debian.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=paulmck@kernel.org \
    --cc=tglx@kernel.org \
    --cc=zhouchuyi@bytedance.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®