diff options
| author | Bjoern B. Brandenburg <bbb@cs.unc.edu> | 2007-09-25 18:51:21 -0400 |
|---|---|---|
| committer | Bjoern B. Brandenburg <bbb@cs.unc.edu> | 2007-09-25 18:51:21 -0400 |
| commit | 44dcbf46a795b6ebd124a6a64ab6e067f7eba840 (patch) | |
| tree | 675ac285014ffa86ca9f0bc969276990e09af225 /include/linux | |
| parent | b36efa1845c84d02414bd01ff326d1073c5b5dbf (diff) | |
Add TRACE_BUG_ON() macro.
For debugging purposes, use where a kernel panic would not be very helpful
and the system isn't going down anyway.
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/litmus.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/litmus.h b/include/linux/litmus.h index df435260cd..27427345da 100644 --- a/include/linux/litmus.h +++ b/include/linux/litmus.h | |||
| @@ -106,6 +106,9 @@ extern spinlock_t litmus_task_set_lock; | |||
| 106 | #define TRACE_CUR(fmt, args...) \ | 106 | #define TRACE_CUR(fmt, args...) \ |
| 107 | TRACE_TASK(current, fmt, ## args) | 107 | TRACE_TASK(current, fmt, ## args) |
| 108 | 108 | ||
| 109 | #define TRACE_BUG_ON(cond) do { if (cond) TRACE("BUG_ON(%s) at %s:%d\n", \ | ||
| 110 | #cond, __FILE__, __LINE__); } while(0); | ||
| 111 | |||
| 109 | /* in_list - is a given list_head queued on some list? | 112 | /* in_list - is a given list_head queued on some list? |
| 110 | */ | 113 | */ |
| 111 | static inline int in_list(struct list_head* list) | 114 | static inline int in_list(struct list_head* list) |
