Re: [PATCH] BUG_ON() not arch-specific.

David Woodhouse (dwmw2@infradead.org)
Wed, 05 Dec 2001 14:42:32 +0000


rusty@rustcorp.com.au said:
> --- linux-2.5.1-pre5/include/linux/kernel.h Wed Dec 5 16:49:14 2001
> +++ working-2.5.1-pre5-percpu/include/linux/kernel.h Wed Dec 5 18:12:15 2001
> @@ -176,4 +176,5 @@
> char _f[20-2*sizeof(long)-sizeof(int)]; /* Padding: libc5 uses this.. */
> };
>
> +#define BUG_ON(condition) do { if (unlikely((condition)!=0)) BUG(); } while(0)

You'll need to add #include <linux/compiler.h> to linux/kernel.h if you do
that. Let's not make the include files any more broken than they already
are :)

--
dwmw2

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/