1 /* SPDX-License-Identifier: GPL-2.0-only */
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
),
23 __entry
->id
= wdd
->id
;
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
),
34 DEFINE_EVENT(watchdog_template
, watchdog_ping
,
35 TP_PROTO(struct watchdog_device
*wdd
, int err
),
38 DEFINE_EVENT(watchdog_template
, watchdog_stop
,
39 TP_PROTO(struct watchdog_device
*wdd
, int 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
),
50 __field(unsigned int, timeout
)
55 __entry
->id
= wdd
->id
;
56 __entry
->timeout
= timeout
;
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>