diff options
| author | Linus Torvalds <[email protected]> | 2007-09-10 14:36:37 -0700 |
|---|---|---|
| committer | Linus Torvalds <[email protected]> | 2007-09-10 14:36:37 -0700 |
| commit | 3c038f97e4b14c322b49f13578e0714e1a2ece53 (patch) | |
| tree | c6d1370339a47fbc89c1913f6a8683f257ef3ef4 /fs/xfs/support/debug.h | |
| parent | 83dc3d43ce06d3466f48046577331d06a40b8344 (diff) | |
| parent | 5995cb7d805496362e5af73235145667096fbc6f (diff) | |
Merge branch 'for-linus' of git://oss.sgi.com:8090/xfs/xfs-2.6
* 'for-linus' of git://oss.sgi.com:8090/xfs/xfs-2.6:
[XFS] fix nasty quota hashtable allocation bug
[XFS] fix sparse shadowed variable warnings
[XFS] fix ASSERT and ASSERT_ALWAYS
[XFS] Fix sparse warning in kmem_shake_allow
[XFS] Fix sparse NULL vs 0 warnings
[XFS] Set filestreams object timeout to something sane.
Diffstat (limited to 'fs/xfs/support/debug.h')
| -rw-r--r-- | fs/xfs/support/debug.h | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/fs/xfs/support/debug.h b/fs/xfs/support/debug.h index a27a7c8c0526..855da0408647 100644 --- a/fs/xfs/support/debug.h +++ b/fs/xfs/support/debug.h @@ -34,10 +34,10 @@ extern void cmn_err(int, char *, ...) extern void assfail(char *expr, char *f, int l); #define ASSERT_ALWAYS(expr) \ - (unlikely((expr) != 0) ? (void)0 : assfail(#expr, __FILE__, __LINE__)) + (unlikely(expr) ? (void)0 : assfail(#expr, __FILE__, __LINE__)) #ifndef DEBUG -# define ASSERT(expr) ((void)0) +#define ASSERT(expr) ((void)0) #ifndef STATIC # define STATIC static noinline @@ -49,8 +49,10 @@ extern void assfail(char *expr, char *f, int l); #else /* DEBUG */ -# define ASSERT(expr) ASSERT_ALWAYS(expr) -# include <linux/random.h> +#include <linux/random.h> + +#define ASSERT(expr) \ + (unlikely(expr) ? (void)0 : assfail(#expr, __FILE__, __LINE__)) #ifndef STATIC # define STATIC noinline |