Re: [PATCH 01/12] DRBD: lru_cache

From: Nikanth K
Date: Wed Apr 08 2009 - 06:15:29 EST


On Mon, Mar 23, 2009 at 9:17 PM, Philipp Reisner
<philipp.reisner@xxxxxxxxxx> wrote:

> +/* this is developers aid only! */
> +#define PARANOIA_ENTRY() BUG_ON(test_and_set_bit(__LC_PARANOIA, &lc->flags))
> +#define PARANOIA_LEAVE() do { clear_bit(__LC_PARANOIA, &lc->flags); smp_mb__after_clear_bit(); } while (0)
> +#define RETURN(x...) Â Â do { PARANOIA_LEAVE(); return x ; } while (0)
> +


The PARANOIA_LEAVE is used for void functions, so RETURN can be
changed to take a simple non-variadic argument. Or empty RETURN()
could be used everywhere instead of mixing PARANOIA_LEAVE() and
RETURN(). Just to make it consistent.

Also this could be made as nop based on some config debug option?

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