]> git.karo-electronics.de Git - karo-tx-linux.git/commit
ext4_{set,clear}_bit() is defined as __test_and_{set,clear}_bit_le() for
authorAkinobu Mita <akinobu.mita@gmail.com>
Wed, 24 Aug 2011 23:46:26 +0000 (09:46 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 27 Sep 2011 06:58:48 +0000 (16:58 +1000)
commit01733b97765315cb612c604c5b39ec7f9bfc4a78
tree6fe71bd6930daf8836a3bee8b081f3bc29c0d6a4
parente4c05190fcff9c0f83f02ec29a48f21094985d9f
ext4_{set,clear}_bit() is defined as __test_and_{set,clear}_bit_le() for
ext4.  Only two ext4_{set,clear}_bit() calls check the return value.  The
rest of calls ignore the return value and they can be replaced with
__{set,clear}_bit_le().

This changes ext4_{set,clear}_bit() from __test_and_{set,clear}_bit_le()
to __{set,clear}_bit_le() and introduces ext4_test_and_{set,clear}_bit()
for the two places where old bit needs to be returned.

This ext4_{set,clear}_bit() change is considered safe, because if someone
uses these macros without noticing the change, new ext4_{set,clear}_bit
don't have return value and causes compiler errors where the return value
is used.

This also removes unused ext4_find_first_zero_bit().

Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Cc: "Theodore Ts'o" <tytso@mit.edu>
Cc: Andreas Dilger <adilger.kernel@dilger.ca>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
fs/ext4/ext4.h
fs/ext4/ialloc.c