Skip to contentSkip to conversation

timers: replace in_irq() with in_hardirq()

PATCH Superseded [email protected] 2 participants 2 messages Oct 11, 2022 High-resolution timers, timer wheel, clockevents

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 timers: replace in_irq() with in_hardirq()

From: ye xingchen <[email protected]>

Replace the obsolete and ambiguos macro in_irq() with new macro in_hardirq().

---
 kernel/time/timer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/time/timer.c +1 -1
index 717fcb9fb14a..f65e3e00ef61 100644
@@ -1838,7 +1838,7 @@ void update_process_times(int user_tick)
 	run_local_timers();
 	rcu_sched_clock_irq(user_tick);
 #ifdef CONFIG_IRQ_WORK
-	if (in_irq())
+	if (in_hardirq())
 		irq_work_tick();
 #endif
 	scheduler_tick();
Signature · 1 line
2.25.1
#1 lore raw
Quoted 5 lines · On Mon, Oct 10, 2022 at 8:06 PM <[email protected]> wrote:

From: ye xingchen <[email protected]>

Replace the obsolete and ambiguos macro in_irq() with new macro in_hardirq().

Would it make sense to replace both instances of in_irq() in that file at once?

thanks
-john