Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
#include <xen/io/console.h>
-/* TODO - need to define BUG_ON for whole mini-os, need crash-dump as well */
-#define BUG_ON(_cond) do{if(_cond) do_exit();} while(0);
-
static inline struct xencons_interface *xencons_interface(void)
{
return mfn_to_virt(start_info.console.domU.mfn);
} \
} while(0)
+#define BUG_ON(x) ASSERT(!(x))
+
/* Consistency check as much as possible. */
void sanity_check(void);
#include <spinlock.h>
#include <xmalloc.h>
-#define BUG_ON(x) do { \
- if (x) {printk("BUG at %s:%d\n", __FILE__, __LINE__); BUG(); } \
-} while (0)
-
#define min(x,y) ({ \
typeof(x) tmpx = (x); \
typeof(y) tmpy = (y); \