From nobody Sat Feb 7 18:52:21 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 70201339861 for ; Fri, 30 Jan 2026 15:46:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769787984; cv=none; b=cyOFViEeqPCnBk3o8HGhhz4S/mkg7UPJcnMMsvRmW8laDLLa/+efzvy+8fCv+WiqkqDLlbIumKvFQFW/fP5phHO4qlAQU8OX58cd5GKZpYuGFO1YFK2jPpXEhEhJYzxnC7QOln3O8jWg3w9Lr5Pd5oW25qs0z/R5JaN4ZGrOjKc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769787984; c=relaxed/simple; bh=EXUzRxMfXSb3+7phclpiwkMcDwiUwkxxHC0nf0ojyig=; h=Message-ID:Date:From:To:Cc:Subject:References:MIME-Version: Content-Type; b=Ri+ojGr2yWzewr6dhGnT6N9Ru568HzW++qD0E7Yy485NSqviM6xE5bsEqXVHutX3Ku6UI3gA5pHnG8cURMf1DhnkRktmLKIVnb4SqnpWRd0qpIfgLyC6J6WHNV0AJiWDg+jkkLpn5t6YB7/Crer+RM4v86oJMsWkewWPUIlc2aA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=XhTDovIB; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="XhTDovIB" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 17CCAC116D0; Fri, 30 Jan 2026 15:46:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1769787984; bh=EXUzRxMfXSb3+7phclpiwkMcDwiUwkxxHC0nf0ojyig=; h=Date:From:To:Cc:Subject:References:From; b=XhTDovIBpPRjygqA/H47fia6soYAPl0UY1ffVkZKWCpzvhY11i/2kXD4GP8Mg3ag1 bcKBUaEJtmdeqXbHc6D9C3POCHJqvnUDpjbEXwklWof/N5IYTrVhG7zcz8N3Ie6sDH 0jEa4bIFob0QPyghrW/jO0IUlOB7VfLf5N+C2fYgdIht/TQrbzFzTMiXG9ZPu01JlA CmDmJ8IoAQbXiff0O9sw/BMeGfj/bNd6JtRQtZ8hQlIMWh20IjlyVGjtDues34j1uO 6NcaxuCGQ69WLVLRizinQfy8eaHi4JWoErg21y3muVVBr3shJawSWGotIf6svmD9d8 u8HiDHN8t+Zlw== Received: from rostedt by gandalf with local (Exim 4.99.1) (envelope-from ) id 1vlqhj-00000001gUz-2wJL; Fri, 30 Jan 2026 10:46:39 -0500 Message-ID: <20260130154639.550162886@kernel.org> User-Agent: quilt/0.68 Date: Fri, 30 Jan 2026 10:46:08 -0500 From: Steven Rostedt To: linux-kernel@vger.kernel.org Cc: Masami Hiramatsu , Mark Rutland , Mathieu Desnoyers , Andrew Morton , "Paul E. McKenney" , Sebastian Andrzej Siewior , Alexei Starovoitov Subject: [for-next][PATCH 1/4] tracing: perf: Have perf tracepoint callbacks always disable preemption References: <20260130154607.755725833@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" From: Steven Rostedt In preparation to convert protection of tracepoints from being protected by a preempt disabled section to being protected by SRCU, have all the perf callbacks disable preemption as perf expects preemption to be disabled when processing tracepoints. While at it, convert the perf system call callback preempt_disable() to a guard(preempt). Link: https://lore.kernel.org/all/20250613152218.1924093-1-bigeasy@linutron= ix.de/ Link: https://patch.msgid.link/20260108220550.2f6638f3@fedora Cc: Masami Hiramatsu Cc: Mark Rutland Cc: Mathieu Desnoyers Cc: Andrew Morton Cc: "Paul E. McKenney" Cc: Sebastian Andrzej Siewior Cc: Alexei Starovoitov Link: https://patch.msgid.link/20260126231256.174621257@kernel.org Signed-off-by: Steven Rostedt (Google) --- include/trace/perf.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/trace/perf.h b/include/trace/perf.h index a1754b73a8f5..348ad1d9b556 100644 --- a/include/trace/perf.h +++ b/include/trace/perf.h @@ -71,6 +71,7 @@ perf_trace_##call(void *__data, proto) \ u64 __count __attribute__((unused)); \ struct task_struct *__task __attribute__((unused)); \ \ + guard(preempt_notrace)(); \ do_perf_trace_##call(__data, args); \ } =20 @@ -85,9 +86,8 @@ perf_trace_##call(void *__data, proto) \ struct task_struct *__task __attribute__((unused)); \ \ might_fault(); \ - preempt_disable_notrace(); \ + guard(preempt_notrace)(); \ do_perf_trace_##call(__data, args); \ - preempt_enable_notrace(); \ } =20 /* --=20 2.51.0