Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros
bug.h File Reference
#include <linux/compiler.h>
#include <linux/kernel.h>

Go to the source code of this file.

Macros

#define BUG()   do {} while(0)
 
#define BUG_ON(condition)   do { if (condition) ; } while(0)
 
#define WARN_ON(condition)
 
#define WARN(condition, format...)
 
#define WARN_TAINT(condition, taint, format...)   WARN_ON(condition)
 
#define WARN_ON_ONCE(condition)
 
#define WARN_ONCE(condition, format...)
 
#define WARN_TAINT_ONCE(condition, taint, format...)
 
#define WARN_ON_SMP(x)   ({0;})
 

Macro Definition Documentation

#define BUG ( )    do {} while(0)

Definition at line 111 of file bug.h.

#define BUG_ON (   condition)    do { if (condition) ; } while(0)

Definition at line 115 of file bug.h.

#define WARN (   condition,
  format... 
)
Value:
({ \
int __ret_warn_on = !!(condition); \
unlikely(__ret_warn_on); \
})

Definition at line 126 of file bug.h.

#define WARN_ON (   condition)
Value:
({ \
int __ret_warn_on = !!(condition); \
unlikely(__ret_warn_on); \
})

Definition at line 119 of file bug.h.

#define WARN_ON_ONCE (   condition)
Value:
({ \
static bool __section(.data.unlikely) __warned; \
int __ret_warn_once = !!(condition); \
\
if (unlikely(__ret_warn_once)) \
if (WARN_ON(!__warned)) \
__warned = true; \
unlikely(__ret_warn_once); \
})

Definition at line 136 of file bug.h.

#define WARN_ON_SMP (   x)    ({0;})

Definition at line 202 of file bug.h.

#define WARN_ONCE (   condition,
  format... 
)
Value:
({ \
static bool __section(.data.unlikely) __warned; \
int __ret_warn_once = !!(condition); \
\
if (unlikely(__ret_warn_once)) \
if (WARN(!__warned, format)) \
__warned = true; \
unlikely(__ret_warn_once); \
})

Definition at line 146 of file bug.h.

#define WARN_TAINT (   condition,
  taint,
  format... 
)    WARN_ON(condition)

Definition at line 132 of file bug.h.

#define WARN_TAINT_ONCE (   condition,
  taint,
  format... 
)
Value:
({ \
static bool __section(.data.unlikely) __warned; \
int __ret_warn_once = !!(condition); \
\
if (unlikely(__ret_warn_once)) \
if (WARN_TAINT(!__warned, taint, format)) \
__warned = true; \
unlikely(__ret_warn_once); \
})

Definition at line 156 of file bug.h.