Thread (16 messages) 16 messages, 5 authors, 2022-10-11

Re: [RFC PATCH 4/5] irq_work: Trace calls to arch_irq_work_raise()

From: Valentin Schneider <vschneid@redhat.com>
Date: 2022-10-11 15:26:17
Also in: linux-alpha, linux-arm-kernel, linux-mips, linux-riscv, linux-s390, linux-sh, lkml, loongarch, sparclinux

On 08/10/22 15:34, Steven Rostedt wrote:
On Fri,  7 Oct 2022 16:45:32 +0100
Valentin Schneider [off-list ref] wrote:
quoted
 }
 
+static inline void irq_work_raise(void)
+{
+	if (arch_irq_work_has_interrupt())
+		trace_ipi_send_cpu(_RET_IP_, smp_processor_id());
To save on the branch, let's make the above:

	if (trace_ipi_send_cpu_enabled() && arch_irq_work_has_interrupt())

As the "trace_*_enabled()" is a static branch that will make it a nop
when the tracepoint is not enabled.
Makes sense, thanks for the suggestion.
-- Steve

quoted
+
+	arch_irq_work_raise();
+}
+
 /* Enqueue on current CPU, work must already be claimed and preempt disabled */
  
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help