Skip to contentSkip to conversation

FAILED: patch "[PATCH] tracing/osnoise: Call synchronize_rcu() when unregistering" failed to apply to 5.15-stable tree

PATCH [email protected] 1 participant 1 message Jul 21

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer
#0 lore raw

The patch below does not apply to the 5.15-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.

To reproduce the conflict and resubmit, you may use the following commands:

git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-5.15.y
git checkout FETCH_HEAD
git cherry-pick -x fe58f457ad8d0a2bef4e053cfecca4b5cd266b1a
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2026072147-untainted-eradicate-d6f3@gregkh' --subject-prefix 'PATCH 5.15.y' 'HEAD^..'

Possible dependencies:

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

From fe58f457ad8d0a2bef4e053cfecca4b5cd266b1a Mon Sep 17 00:00:00 2001
From: Crystal Wood <[email protected]>
Date: Mon, 8 Jun 2026 23:54:30 -0500
Subject: [PATCH] tracing/osnoise: Call synchronize_rcu() when unregistering

This ensures that any RCU readers traversing the instance list have finished, before releasing the reference on the tracer that the instance points to.

kernel/trace/trace_osnoise.c +3 -1
index 5e83c4f6f2b4..0e1265acd1cc 100644
@@ -179,7 +179,9 @@ static void osnoise_unregister_instance(struct trace_array *tr)
 	if (!found)
 		return;
 
-	kvfree_rcu_mightsleep(inst);
+	/* Do a full sync to ensure that tr remains valid, not just inst */
+	synchronize_rcu();
+	kvfree(inst);
 }
 
 /*