linux-stable/fs/ext4
Jan Kara e386c0272b ext4: do not delete unlinked inode from orphan list on failed truncate
commit ee0ed02ca9 upstream.

It is possible that unlinked inode enters ext4_setattr() (e.g. if
somebody calls ftruncate(2) on unlinked but still open file). In such
case we should not delete the inode from the orphan list if truncate
fails. Note that this is mostly a theoretical concern as filesystem is
corrupted if we reach this path anyway but let's be consistent in our
orphan handling.

Reviewed-by: Ira Weiny <ira.weiny@intel.com>
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Cc: stable@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-05-31 06:48:11 -07:00
..
acl.c ext4: Don't clear SGID when inheriting ACLs 2017-10-12 11:51:26 +02:00
acl.h
balloc.c ext4: check for allocation block validity with block group locked 2018-08-03 07:55:26 +02:00
bitmap.c ext4: remove unused header files 2015-04-02 23:47:42 -04:00
block_validity.c ext4: add missing KERN_CONT to a few more debugging uses 2016-10-15 09:57:31 -04:00
dir.c ext4: avoid divide by zero fault when deleting corrupted inline directories 2018-09-29 03:07:34 -07:00
ext4.h ext4: avoid running out of journal credits when appending to an inline file 2018-10-20 09:51:32 +02:00
ext4_extents.h ext4: verify the depth of extent tree in ext4_find_extent() 2018-07-11 16:26:44 +02:00
ext4_jbd2.c ext4: fix potential use after free in __ext4_journal_stop 2015-10-17 22:57:06 -04:00
ext4_jbd2.h ext4: fix NULL pointer dereference while journal is aborted 2019-03-27 14:13:03 +09:00
extents.c ext4: zero out the unused memory region in the extent tree block 2019-05-21 18:49:01 +02:00
extents_status.c ext4: remove trailing \n from ext4_warning/ext4_error calls 2016-04-27 01:11:21 -04:00
extents_status.h ext4: move procfs registration code to fs/ext4/sysfs.c 2015-09-23 12:46:17 -04:00
file.c ext4: fix data corruption caused by overlapping unaligned and aligned IO 2019-05-21 18:49:01 +02:00
fsync.c ext4: cleanup ext4_sync_parent() 2016-09-05 23:21:43 -04:00
hash.c ext4: remove unused header files 2015-04-02 23:47:42 -04:00
ialloc.c ext4: fix check to prevent initializing reserved inodes 2018-08-15 18:14:41 +02:00
indirect.c ext4: cleanup bh release code in ext4_ind_remove_space() 2019-04-05 22:29:04 +02:00
inline.c ext4: fix a potential fiemap/page fault deadlock w/ inline_data 2019-01-16 22:12:32 +01:00
inode.c ext4: do not delete unlinked inode from orphan list on failed truncate 2019-05-31 06:48:11 -07:00
ioctl.c ext4: actually request zeroing of inode table after grow 2019-05-21 18:48:59 +02:00
Kconfig ext4 crypto: migrate into vfs's crypto engine 2016-07-10 14:01:03 -04:00
Makefile ext4 crypto: migrate into vfs's crypto engine 2016-07-10 14:01:03 -04:00
mballoc.c ext4: fix spectre gadget in ext4_mb_regular_allocator() 2018-08-24 13:12:41 +02:00
mballoc.h ext4: add missing KERN_CONT to a few more debugging uses 2016-10-15 09:57:31 -04:00
migrate.c ext4: fix misspellings in comments. 2016-03-09 23:49:05 -05:00
mmp.c ext4: don't mark mmp buffer head dirty 2018-09-29 03:07:34 -07:00
move_extent.c ext4: fix argument checking in EXT4_IOC_MOVE_EXT 2018-11-13 11:16:52 -08:00
namei.c ext4: fix buffer leak in __ext4_read_dirblock() on error path 2018-11-21 09:26:02 +01:00
page-io.c fs: use mapping_set_error instead of opencoded set_bit 2016-10-11 15:06:33 -07:00
readpage.c Merge branch 'akpm' (patches from Andrew) 2016-07-26 19:55:54 -07:00
resize.c ext4: report real fs size after failed resize 2019-04-20 09:07:46 +02:00
super.c ext4: fix ext4_show_options for file systems w/o journal 2019-05-21 18:48:59 +02:00
symlink.c Merge branch 'work.xattr' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs 2016-10-10 17:11:50 -07:00
sysfs.c ext4: sysfs: print ext4_super_block fields as little-endian 2018-09-05 09:20:06 +02:00
truncate.h ext4: fix races between page faults and hole punching 2015-12-07 14:28:03 -05:00
xattr.c ext4: include terminating u32 in size of xattr entries when expanding inodes 2019-01-09 16:16:43 +01:00
xattr.h ext4: fix deadlock between inline_data and ext4_expand_extra_isize_ea() 2017-03-12 06:41:41 +01:00
xattr_security.c switch xattr_handler->set() to passing dentry and inode separately 2016-05-27 15:39:43 -04:00
xattr_trusted.c switch xattr_handler->set() to passing dentry and inode separately 2016-05-27 15:39:43 -04:00
xattr_user.c switch xattr_handler->set() to passing dentry and inode separately 2016-05-27 15:39:43 -04:00