Merge tag 'trace-printf-v6.13' of git://git.kernel.org/pub/scm/linux/kernel/git/trace...
[drm/drm-misc.git] / include / trace / events / watchdog.h
blobbeb9bb3424c8e10113cac0a26416e9421c823709
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 #undef TRACE_SYSTEM
3 #define TRACE_SYSTEM watchdog
5 #if !defined(_TRACE_WATCHDOG_H) || defined(TRACE_HEADER_MULTI_READ)
6 #define _TRACE_WATCHDOG_H
8 #include <linux/watchdog.h>
9 #include <linux/tracepoint.h>
11 DECLARE_EVENT_CLASS(watchdog_template,
13 TP_PROTO(struct watchdog_device *wdd, int err),
15 TP_ARGS(wdd, err),
17 TP_STRUCT__entry(
18 __field(int, id)
19 __field(int, err)
22 TP_fast_assign(
23 __entry->id = wdd->id;
24 __entry->err = err;
27 TP_printk("watchdog%d err=%d", __entry->id, __entry->err)
30 DEFINE_EVENT(watchdog_template, watchdog_start,
31 TP_PROTO(struct watchdog_device *wdd, int err),
32 TP_ARGS(wdd, err));
34 DEFINE_EVENT(watchdog_template, watchdog_ping,
35 TP_PROTO(struct watchdog_device *wdd, int err),
36 TP_ARGS(wdd, err));
38 DEFINE_EVENT(watchdog_template, watchdog_stop,
39 TP_PROTO(struct watchdog_device *wdd, int err),
40 TP_ARGS(wdd, err));
42 TRACE_EVENT(watchdog_set_timeout,
44 TP_PROTO(struct watchdog_device *wdd, unsigned int timeout, int err),
46 TP_ARGS(wdd, timeout, err),
48 TP_STRUCT__entry(
49 __field(int, id)
50 __field(unsigned int, timeout)
51 __field(int, err)
54 TP_fast_assign(
55 __entry->id = wdd->id;
56 __entry->timeout = timeout;
57 __entry->err = err;
60 TP_printk("watchdog%d timeout=%u err=%d", __entry->id, __entry->timeout, __entry->err)
63 #endif /* !defined(_TRACE_WATCHDOG_H) || defined(TRACE_HEADER_MULTI_READ) */
65 /* This part must be outside protection */
66 #include <trace/define_trace.h>