From: Joel Fernandes <joelagnelf@nvidia.com>
To: linux-kernel@vger.kernel.org,
Frederic Weisbecker <frederic@kernel.org>,
"Paul E. McKenney" <paulmck@kernel.org>
Cc: Xiongfeng Wang <wangxiongfeng2@huawei.com>,
rcu@vger.kernel.org, bpf@vger.kernel.org
Subject: Re: [PATCH 1/2] context_tracking: Provide helper to determine if we're in IRQ
Date: Mon, 9 Jun 2025 14:05:16 -0400 [thread overview]
Message-ID: <cb7ed8e5-220d-41f0-8743-5a7a4627443d@nvidia.com> (raw)
In-Reply-To: <20250609180125.2988129-1-joelagnelf@nvidia.com>
On 6/9/2025 2:01 PM, Joel Fernandes wrote:
> context_tracking keeps track of whether we're handling IRQ well after
> the preempt masks give take it off their books. We need this
> functionality in a follow-up patch to fix a bug. Provide a helper API
> for the same.
>
> Signed-off-by: Joel Fernandes <joelagnelf@nvidia.com>
> ---
> include/linux/context_tracking_irq.h | 2 ++
> kernel/context_tracking.c | 12 ++++++++++++
> 2 files changed, 14 insertions(+)
>
> diff --git a/include/linux/context_tracking_irq.h b/include/linux/context_tracking_irq.h
> index 197916ee91a4..35a5ad971514 100644
> --- a/include/linux/context_tracking_irq.h
> +++ b/include/linux/context_tracking_irq.h
> @@ -9,6 +9,7 @@ void ct_irq_enter_irqson(void);
> void ct_irq_exit_irqson(void);
> void ct_nmi_enter(void);
> void ct_nmi_exit(void);
> +bool ct_in_irq(void);
> #else
> static __always_inline void ct_irq_enter(void) { }
> static __always_inline void ct_irq_exit(void) { }
> @@ -16,6 +17,7 @@ static inline void ct_irq_enter_irqson(void) { }
> static inline void ct_irq_exit_irqson(void) { }
> static __always_inline void ct_nmi_enter(void) { }
> static __always_inline void ct_nmi_exit(void) { }
> +static inline bool ct_in_irq(void) { return false; }
I did s/inline/__always_inline/ here. Will send with next posting.
thanks,
- Joel
next prev parent reply other threads:[~2025-06-09 18:05 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-09 18:01 Joel Fernandes
2025-06-09 18:01 ` [PATCH 2/2] rcu: Fix lockup when RCU reader used while IRQ exiting Joel Fernandes
2025-06-09 19:49 ` Boqun Feng
2025-06-09 23:26 ` Frederic Weisbecker
2025-06-10 0:49 ` Boqun Feng
2025-06-10 12:23 ` Frederic Weisbecker
2025-06-10 15:47 ` Joel Fernandes
2025-06-12 3:06 ` Xiongfeng Wang
2025-06-12 11:37 ` Frederic Weisbecker
2025-06-11 16:05 ` Boqun Feng
2025-06-11 16:16 ` Paul E. McKenney
2025-06-11 16:21 ` Boqun Feng
2025-06-09 18:05 ` Joel Fernandes [this message]
2025-06-11 16:25 ` [PATCH 1/2] context_tracking: Provide helper to determine if we're in IRQ Frederic Weisbecker
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=cb7ed8e5-220d-41f0-8743-5a7a4627443d@nvidia.com \
--to=joelagnelf@nvidia.com \
--cc=bpf@vger.kernel.org \
--cc=frederic@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=paulmck@kernel.org \
--cc=rcu@vger.kernel.org \
--cc=wangxiongfeng2@huawei.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®