xfs: fix xfs_debug warnings
authorChristoph Hellwig <[email protected]>
Sat, 2 Apr 2011 18:13:40 +0000 (18:13 +0000)
committerAlex Elder <[email protected]>
Fri, 8 Apr 2011 13:09:24 +0000 (08:09 -0500)
commit957935dcd8e11d6f789b4ed769b376040e15565b
tree6f120bac2011bdba637f39d3704ec0272b883726
parentecb697c16c1718ae97bb73ce41a5d5ac2aed29ec
xfs: fix xfs_debug warnings

For a CONFIG_XFS_DEBUG=n build gcc complains about statements with no
effect in xfs_debug:

fs/xfs/quota/xfs_qm_syscalls.c: In function 'xfs_qm_scall_trunc_qfiles':
fs/xfs/quota/xfs_qm_syscalls.c:291:3: warning: statement with no effect

The reason for that is that the various new xfs message functions have a
return value which is never used, and in case of the non-debug build
xfs_debug the macro evaluates to a plain 0 which produces the above
warnings.  This can be fixed by turning xfs_debug into an inline function
instead of a macro, but in addition to that I've also changed all the
message helpers to return void as we never use their return values.

Signed-off-by: Christoph Hellwig <[email protected]>
Reviewed-by: Dave Chinner <[email protected]>
Signed-off-by: Alex Elder <[email protected]>
fs/xfs/linux-2.6/xfs_message.c
fs/xfs/linux-2.6/xfs_message.h