Jan Kara
9f75306bea
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 >
2017-11-02 07:16:21 +01:00
..
2017-06-08 00:46:47 +02:00
2015-04-29 10:34:00 +02:00
2013-05-07 20:16:25 -07:00
2015-04-29 10:34:00 +02:00
2013-05-31 15:17:56 -04:00
2017-06-19 20:28:15 +02:00
2015-04-29 10:34:00 +02:00
2017-06-20 14:04:42 +02:00
2015-04-29 10:34:00 +02:00
2013-11-29 11:11:53 -08:00
2015-04-29 10:34:00 +02:00
2016-02-25 11:57:46 -08:00
2013-05-01 14:08:52 -07:00
2016-08-27 11:40:31 +02:00
2016-03-16 08:41:37 -07:00
2014-02-13 13:48:00 -08:00
2015-04-29 10:34:00 +02:00
2017-06-08 00:46:47 +02:00
2017-06-08 00:46:47 +02:00
2017-11-02 07:16:21 +01:00
2017-06-08 00:46:49 +02:00
2017-06-20 14:04:27 +02:00
2017-11-02 07:16:17 +01:00
2017-11-01 22:12:44 +01:00
2017-06-20 14:04:50 +02:00
2015-10-01 12:07:34 +02:00
2015-10-01 12:07:34 +02:00
2017-02-10 11:03:30 +01:00
2015-09-21 10:00:10 -07:00
2013-04-29 15:41:42 -04:00
2017-06-21 15:42:43 +02:00
2017-02-10 11:03:30 +01:00
2013-05-03 09:56:25 -07:00
2017-06-20 08:02:35 +02:00
2017-06-08 00:46:47 +02:00
2017-06-08 00:46:47 +02:00
2016-03-03 15:06:20 -08:00
2015-04-29 10:34:00 +02:00
2017-06-20 14:04:24 +02:00
2017-06-20 14:04:53 +02:00
2016-08-27 11:40:30 +02:00
2015-08-16 20:51:35 -07:00
2013-05-07 20:16:25 -07:00
2017-06-20 08:03:01 +02:00
2015-06-05 23:19:54 -07:00
2017-06-21 15:42:43 +02:00
2017-02-10 11:04:02 +01:00
2013-05-31 15:17:31 -04:00
2015-01-29 17:40:57 -08:00
2017-06-08 00:46:47 +02:00
2016-02-19 14:22:39 -08:00
2017-06-08 00:46:56 +02:00
2016-02-25 11:57:48 -08:00
2013-04-30 09:36:50 -07:00
2017-06-20 14:04:32 +02:00
2016-02-25 11:57:46 -08:00
2014-06-16 13:42:52 -07:00
2013-05-01 17:51:54 -07:00
2013-05-02 10:16:16 -07:00
2016-02-19 14:22:41 -08:00
2013-04-29 15:40:23 -04:00
2013-04-30 17:04:03 -07:00
2014-03-23 21:38:21 -07:00
2013-10-05 07:13:09 -07:00
2017-06-08 00:46:49 +02:00
2014-11-14 08:47:54 -08:00
2013-05-04 15:03:05 -04:00
2013-05-07 20:16:25 -07:00
2017-02-06 23:33:05 +01:00
2017-06-20 14:04:14 +02:00
2014-02-13 13:48:00 -08:00
2017-11-02 07:16:05 +01:00
2013-05-01 07:21:43 -07:00
2017-11-01 22:12:42 +01:00
2015-06-05 23:20:00 -07:00
2015-07-03 19:48:08 -07:00
2014-02-22 12:41:25 -08:00
2015-01-16 06:59:02 -08:00
2017-06-08 00:46:47 +02:00
2015-07-10 10:40:22 -07:00
2015-07-03 19:48:08 -07:00
2017-06-20 08:02:37 +02:00
2013-04-30 17:04:04 -07:00
2015-04-29 10:34:00 +02:00
2016-03-09 15:31:53 -08:00
2013-05-01 17:51:54 -07:00
2014-02-06 11:08:16 -08:00
2016-03-03 15:06:24 -08:00
2015-01-08 09:58:16 -08:00
2015-07-03 19:48:08 -07:00
2016-08-21 23:22:36 +02:00
2013-05-31 15:16:33 -04:00
2013-05-01 17:51:54 -07:00
2017-06-08 00:46:47 +02:00
2014-02-13 13:48:00 -08:00
2017-02-10 11:03:29 +01:00
2015-08-16 20:51:42 -07:00
2017-06-20 14:04:20 +02:00
2015-01-29 17:40:57 -08:00
2013-10-18 07:45:44 -07:00
2017-02-10 11:03:29 +01:00