aboutsummaryrefslogtreecommitdiff
path: root/include/linux/list.h
diff options
context:
space:
mode:
authorJan Kara <jack@suse.cz>2016-08-11 12:38:55 -0400
committerMoyster <oysterized@gmail.com>2017-11-06 15:28:51 +0100
commite1330eec3f920f60c0ca7b0e86199eca4ae2cf88 (patch)
tree157dbb2541b72b8a10c40424a9c4e19e8c6e4058 /include/linux/list.h
parentb9700d07f1eb3e5b35174d7dcef451d806993230 (diff)
ext4: avoid deadlock when expanding inode size
commit 2e81a4eeedcaa66e35f58b81e0755b87057ce392 upstream. When we need to move xattrs into external xattr block, we call ext4_xattr_block_set() from ext4_expand_extra_isize_ea(). That may end up calling ext4_mark_inode_dirty() again which will recurse back into the inode expansion code leading to deadlocks. Protect from recursion using EXT4_STATE_NO_EXPAND inode flag and move its management into ext4_expand_extra_isize_ea() since its manipulation is safe there (due to xattr_sem) from possible races with ext4_xattr_set_handle() which plays with it as well. CC: stable@vger.kernel.org # 4.4.x Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Willy Tarreau <w@1wt.eu>
Diffstat (limited to 'include/linux/list.h')
0 files changed, 0 insertions, 0 deletions