diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/litmus/debug_trace.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/include/litmus/debug_trace.h b/include/litmus/debug_trace.h index 48d086d5a44c..1266ac6a760c 100644 --- a/include/litmus/debug_trace.h +++ b/include/litmus/debug_trace.h | |||
@@ -28,8 +28,11 @@ extern atomic_t __log_seq_no; | |||
28 | TRACE_ARGS, ## args) | 28 | TRACE_ARGS, ## args) |
29 | 29 | ||
30 | #define TRACE_TASK(t, fmt, args...) \ | 30 | #define TRACE_TASK(t, fmt, args...) \ |
31 | TRACE("(%s/%d:%d) " fmt, (t)->comm, (t)->pid, \ | 31 | TRACE("(%s/%d:%d) " fmt, \ |
32 | (t)->rt_param.job_params.job_no, ##args) | 32 | t ? (t)->comm : "null", \ |
33 | t ? (t)->pid : 0, \ | ||
34 | t ? (t)->rt_param.job_params.job_no : 0, \ | ||
35 | ##args) | ||
33 | 36 | ||
34 | #define TRACE_CUR(fmt, args...) \ | 37 | #define TRACE_CUR(fmt, args...) \ |
35 | TRACE_TASK(current, fmt, ## args) | 38 | TRACE_TASK(current, fmt, ## args) |