Palacios Public Git Repository

To checkout Palacios execute

  git clone http://v3vee.org/palacios/palacios.web/palacios.git
This will give you the master branch. You probably want the devel branch or one of the release branches. To switch to the devel branch, simply execute
  cd palacios
  git checkout --track -b devel origin/devel
The other branches are similar.


Merge branch 'devel'
[palacios.git] / kitten / include / arch-generic / bug.h
1 #ifndef _ARCH_GENERIC_BUG_H
2 #define _ARCH_GENERIC_BUG_H
3
4 #include <lwk/compiler.h>
5
6 #ifndef HAVE_ARCH_BUG
7 #define BUG() do { \
8         printk("BUG: failure at %s:%d/%s()!\n", __FILE__, __LINE__, __FUNCTION__); \
9         panic("BUG!"); \
10 } while (0)
11 #endif
12
13 #ifndef HAVE_ARCH_BUG_ON
14 #define BUG_ON(condition) do { if (unlikely((condition)!=0)) BUG(); } while(0)
15 #endif
16
17 #ifndef HAVE_ARCH_ASSERT
18 #define ASSERT(condition) do { if (unlikely((condition)!=1)) BUG(); } while(0)
19 #endif
20
21 #ifndef HAVE_ARCH_WARN_ON
22 #define WARN_ON(condition) do { \
23         if (unlikely((condition)!=0)) { \
24                 printk("BUG: warning at %s:%d/%s()\n", __FILE__, __LINE__, __FUNCTION__); \
25                 /* TODO FIX ME */ \
26                 /* dump_stack(); */ \
27         } \
28 } while (0)
29 #endif
30
31 #endif