]> git.karo-electronics.de Git - karo-tx-linux.git/commit
ext4: Use bitops to read/modify EXT4_I(inode)->i_state
authorTheodore Ts'o <tytso@mit.edu>
Mon, 31 May 2010 02:49:27 +0000 (22:49 -0400)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 2 Aug 2010 17:21:12 +0000 (10:21 -0700)
commit884aefaa8bbc07cdce4e77637f810cdab5940957
treec69b2a20e32639335c9e4f6833653e3da450cdd1
parent6595162b533a3e8d450dd13caec28758892d1be1
ext4: Use bitops to read/modify EXT4_I(inode)->i_state

commit 19f5fb7ad679bb361222c7916086435020c37cce upstream (as of v2.6.33-git11)

At several places we modify EXT4_I(inode)->i_state without holding
i_mutex (ext4_release_file, ext4_bmap, ext4_journalled_writepage,
ext4_do_update_inode, ...). These modifications are racy and we can
lose updates to i_state. So convert handling of i_state to use bitops
which are atomic.

Cc: Jan Kara <jack@suse.cz>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
fs/ext4/ext4.h
fs/ext4/extents.c
fs/ext4/file.c
fs/ext4/ialloc.c
fs/ext4/inode.c
fs/ext4/migrate.c
fs/ext4/xattr.c