[PATCH 2/3] libxlog: sync up with 2.6.38 kernel code
Christoph Hellwig
hch at infradead.org
Mon Jan 24 02:47:32 CST 2011
> +typedef int32_t atomic_t;
> +typedef int64_t atomic64_t;
> +
> +#define atomic_inc_return(x) (++(*(x)))
> +#define atomic_dec_return(x) (--(*(x)))
> +
> +#define atomic64_read(x) *(x)
> +#define atomic64_set(x, v) (*(x) = v)
These defintions are pretty dangerous if we ever happens to use
them in multi-threaded code like repair. Currently we're not,
but they should grow a larger warning comment.
> --- /dev/null
> +++ b/include/hlist.h
Why not add the hlist helpers to list.h, like in the kernel tree?
Otherwise looks good,
Reviewed-by: Christoph Hellwig <hch at lst.de>
More information about the xfs
mailing list