aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ufs/ialloc.c
diff options
context:
space:
mode:
authorEvgeniy Dushistov <dushistov@mail.ru>2007-03-16 17:38:07 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-03-16 22:25:03 -0400
commit2189850f42beff23af32d847bd043cd1d1811a80 (patch)
treeeb7f6b8ab11ee7458b7759788dc3516c0202973c /fs/ufs/ialloc.c
parent94985134b7b46848267ed6b734320db01c974e72 (diff)
[PATCH] ufs2: more correct work with time
This patch corrects work with time in UFS2 case. 1) According to UFS2 disk layout modification/access and so on "time" should be hold in two variables one 64bit for seconds and another 32bit for nanoseconds, at now for some unknown reason we suppose that "inode time" holds in three variables 32bit for seconds, 32bit for milliseconds and 32bit for nanoseconds. 2) We set amount of nanoseconds in "VFS inode" to 0 during read, instead of getting values from "on disk inode"(this should close http://bugzilla.kernel.org/show_bug.cgi?id=7991). Signed-off-by: Evgeniy Dushistov <dushistov@mail.ru> Cc: Bjoern Jacke <bjoern@j3e.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/ufs/ialloc.c')
-rw-r--r--fs/ufs/ialloc.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/ufs/ialloc.c b/fs/ufs/ialloc.c
index b868878009b6..c28a8b6f2feb 100644
--- a/fs/ufs/ialloc.c
+++ b/fs/ufs/ialloc.c
@@ -343,9 +343,8 @@ cg_found:
343 lock_buffer(bh); 343 lock_buffer(bh);
344 ufs2_inode = (struct ufs2_inode *)bh->b_data; 344 ufs2_inode = (struct ufs2_inode *)bh->b_data;
345 ufs2_inode += ufs_inotofsbo(inode->i_ino); 345 ufs2_inode += ufs_inotofsbo(inode->i_ino);
346 ufs2_inode->ui_birthtime.tv_sec = 346 ufs2_inode->ui_birthtime = cpu_to_fs64(sb, CURRENT_TIME.tv_sec);
347 cpu_to_fs32(sb, CURRENT_TIME_SEC.tv_sec); 347 ufs2_inode->ui_birthnsec = cpu_to_fs32(sb, CURRENT_TIME.tv_nsec);
348 ufs2_inode->ui_birthtime.tv_usec = 0;
349 mark_buffer_dirty(bh); 348 mark_buffer_dirty(bh);
350 unlock_buffer(bh); 349 unlock_buffer(bh);
351 if (sb->s_flags & MS_SYNCHRONOUS) 350 if (sb->s_flags & MS_SYNCHRONOUS)