Linux kernel mirror (for testing)
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel
os
linux
1/* SPDX-License-Identifier: GPL-2.0 */
2#ifndef _LINUX_FTRACE_IRQ_H
3#define _LINUX_FTRACE_IRQ_H
4
5#ifdef CONFIG_HWLAT_TRACER
6extern bool trace_hwlat_callback_enabled;
7extern void trace_hwlat_callback(bool enter);
8#endif
9
10static inline void ftrace_nmi_enter(void)
11{
12#ifdef CONFIG_HWLAT_TRACER
13 if (trace_hwlat_callback_enabled)
14 trace_hwlat_callback(true);
15#endif
16}
17
18static inline void ftrace_nmi_exit(void)
19{
20#ifdef CONFIG_HWLAT_TRACER
21 if (trace_hwlat_callback_enabled)
22 trace_hwlat_callback(false);
23#endif
24}
25
26#endif /* _LINUX_FTRACE_IRQ_H */