]> git.baikalelectronics.ru Git - kernel.git/commit
fat: provide option for setting timezone offset
authorJan Kara <jack@suse.cz>
Tue, 18 Dec 2012 00:02:58 +0000 (16:02 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 18 Dec 2012 01:15:22 +0000 (17:15 -0800)
commit8b9e95cc10a5c0ea5cde0325dedc5ce43a46d66f
treeffe31e639221d1f2434f873f93d3ee654cbfb9da
parent4f0d8c604266e8c43e65cf795586c3b9931400b9
fat: provide option for setting timezone offset

So far FAT either offsets time stamps by sys_tz.minuteswest or leaves them
as they are (when tz=UTC mount option is used).  However in some cases it
is useful if one can specify time stamp offset on his own (e.g.  when time
zone of the camera connected is different from time zone of the computer,
or when HW clock is in UTC and thus sys_tz.minuteswest == 0).

So provide a mount option time_offset= which allows user to specify offset
in minutes that should be applied to time stamps on the filesystem.

akpm: this code would work incorrectly when used via `mount -o remount',
because cached inodes would not be updated.  But fatfs's fat_remount() is
basically a no-op anyway.

Signed-off-by: Jan Kara <jack@suse.cz>
Acked-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Documentation/filesystems/vfat.txt
fs/fat/fat.h
fs/fat/inode.c
fs/fat/misc.c