Maybe call panic() or similar, instead of oops-ing?
> Here's the corrected version:
[...]
> +#ifdef DEBUG
'DEBUG' is far too general. __USING_KASSERT?
> +#else
> +#define kassert(cond) (void) abs(cond)
> +#define kassertoops(cond) (void) abs(cond)
> +#endif
Any code depending on assert evaluating the condition is broken IMHO.
Doing so breaks an important feature of assert: it evaluates to nothing
when disabled. Your above example violates the principle of least
surprise; instead, it should be ((void)0)
Once it does that, please do submit it to the Upper Penguins. ;-)
Jeff
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/