remarkable-linux/fs/ext4
Jan Kara ffacfa7a79 ext4: Fix truncation of symlinks after failed write
Contents of long symlinks is written via standard write methods. So
when the write fails, we add inode to orphan list. But symlinks don't
have .truncate method defined so nobody properly removes them from the
on disk orphan list.

Fix this by calling ext4_truncate() directly instead of calling
vmtruncate() (which is saner anyway since we don't need anything
vmtruncate() does except from calling .truncate in these paths).  We
also add inode to orphan list only if ext4_can_truncate() is true
(currently, it can be false for symlinks when there are no blocks
allocated) - otherwise orphan list processing will complain and
ext4_truncate() will not remove inode from on-disk orphan list.

Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2009-07-13 16:22:22 -04:00
..
acl.c helpers for acl caching + switch to those 2009-06-24 08:17:07 -04:00
acl.h switch ext4 to inode->i_acl 2009-06-24 08:17:04 -04:00
balloc.c ext4: Convert ext4_lock_group to use sb_bgl_lock 2009-05-02 20:35:09 -04:00
bitmap.c ext4: Change unsigned long to unsigned int 2008-11-05 00:14:04 -05:00
block_validity.c ext4: Add a comprehensive block validity check to ext4_get_blocks() 2009-05-17 15:38:01 -04:00
dir.c ext4: Define a new set of flags for ext4_get_blocks() 2009-05-14 00:58:52 -04:00
ext4.h ext4: naturally align struct ext4_allocation_request 2009-07-13 10:24:17 -04:00
ext4_extents.h ext4: online defrag -- Add EXT4_IOC_MOVE_EXT ioctl 2009-06-17 19:24:03 -04:00
ext4_jbd2.c ext4: Allow ext4 to run without a journal 2009-01-07 00:06:22 -05:00
ext4_jbd2.h ext4: Remove "extents" mount option 2009-01-06 14:53:16 -05:00
extents.c ext4: online defrag -- Add EXT4_IOC_MOVE_EXT ioctl 2009-06-17 19:24:03 -04:00
file.c ext4: update the s_last_mounted field in the superblock 2009-06-13 10:09:48 -04:00
fsync.c ext4: convert instrumentation from markers to tracepoints 2009-06-17 11:48:11 -04:00
hash.c ext4: Add support for non-native signed/unsigned htree hash algorithms 2008-10-28 13:21:44 -04:00
ialloc.c ext4: teach the inode allocator to use a goal inode number 2009-06-13 11:45:35 -04:00
inode.c ext4: Fix truncation of symlinks after failed write 2009-07-13 16:22:22 -04:00
ioctl.c ext4: online defrag -- Add EXT4_IOC_MOVE_EXT ioctl 2009-06-17 19:24:03 -04:00
Kconfig trivial: fix typos/grammar errors in Kconfig texts 2009-03-30 15:22:01 +02:00
Makefile ext4: online defrag -- Add EXT4_IOC_MOVE_EXT ioctl 2009-06-17 19:24:03 -04:00
mballoc.c ext4: Use rcu_barrier() on module unload. 2009-07-05 22:29:27 -04:00
mballoc.h ext4: Move fs/ext4/group.h into ext4.h 2009-05-01 19:44:44 -04:00
migrate.c ext4: teach the inode allocator to use a goal inode number 2009-06-13 11:45:35 -04:00
move_extent.c ext4: online defrag -- Add EXT4_IOC_MOVE_EXT ioctl 2009-06-17 19:24:03 -04:00
namei.c ext4: teach the inode allocator to use a goal inode number 2009-06-13 11:45:35 -04:00
resize.c block: rename CONFIG_LBD to CONFIG_LBDAF 2009-06-19 08:08:50 +02:00
super.c switch ext4 to inode->i_acl 2009-06-24 08:17:04 -04:00
symlink.c
xattr.c ext4: Use lowercase names of quota functions 2009-03-26 02:18:36 +01:00
xattr.h
xattr_security.c
xattr_trusted.c
xattr_user.c