linux_dsm_epyc7002/fs/ufs
Evgeniy Dushistov 10e5dce07e [PATCH] ufs: truncate should allocate block for last byte
This patch fixes buggy behaviour of UFS
in such kind of scenario:
open(, O_TRUNC...)
ftruncate(, 1024)
ftruncate(, 0)

Such a scenario causes ufs_panic and remount read-only.  This happen
because of according to specification UFS should always allocate block for
last byte, and many parts of our implementation rely on this, but
`ufs_truncate' doesn't care about this.

To make possible return error code and to know about old size, this patch
removes `truncate' from ufs inode_operations and uses `setattr' method to
call ufs_truncate.

Signed-off-by: Evgeniy Dushistov <dushistov@mail.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-07-01 09:56:03 -07:00
..
balloc.c [PATCH] ufs: truncate should allocate block for last byte 2006-07-01 09:56:03 -07:00
cylinder.c [PATCH] ufs: easy debug 2006-06-25 10:01:03 -07:00
dir.c [PATCH] ufs: little directory lookup optimization 2006-06-25 10:01:03 -07:00
file.c [PATCH] ufs: truncate should allocate block for last byte 2006-07-01 09:56:03 -07:00
ialloc.c [PATCH] ufs: ubh_ll_rw_block cleanup 2006-06-25 10:01:04 -07:00
inode.c [PATCH] ufs: truncate should allocate block for last byte 2006-07-01 09:56:03 -07:00
Makefile Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
namei.c [PATCH] ufs: easy debug 2006-06-25 10:01:03 -07:00
super.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
swab.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
symlink.c [PATCH] Fix up symlink function pointers 2005-08-19 18:08:21 -07:00
truncate.c [PATCH] ufs: truncate should allocate block for last byte 2006-07-01 09:56:03 -07:00
util.c [PATCH] ufs: truncate should allocate block for last byte 2006-07-01 09:56:03 -07:00
util.h [PATCH] ufs: truncate should allocate block for last byte 2006-07-01 09:56:03 -07:00