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
..
2006-06-26 09:58:18 -07:00
2006-06-30 18:23:04 +02:00
2006-06-26 18:35:02 +02:00
2006-01-11 18:42:13 -08:00
2006-01-10 08:01:25 -08:00
2005-04-16 15:20:36 -07:00
2005-04-16 15:20:36 -07:00
2006-06-23 17:10:39 +02:00
2006-01-08 20:12:40 -08:00
2006-04-02 13:37:19 +02:00
2006-04-11 13:53:33 +02:00
2005-10-30 17:37:32 -08:00
2006-06-29 14:56:12 -07:00
2006-06-26 09:58:17 -07:00
2006-03-28 09:16:08 -08:00
2006-06-23 07:42:49 -07:00
2006-06-26 09:58:17 -07:00
2005-11-07 18:18:11 -08:00
2005-04-16 15:20:36 -07:00
2006-03-23 07:38:11 -08:00
2006-03-23 07:38:11 -08:00
2006-03-23 07:38:12 -08:00
2006-06-23 07:42:49 -07:00
2005-04-16 15:20:36 -07:00