fuse: Trust kernel i_mtime only
commitb0aa760652179072119582375f8dc896ed5b5dfd
authorMaxim Patlasov <MPatlasov@parallels.com>
Thu, 26 Dec 2013 15:51:11 +0000 (26 19:51 +0400)
committerMiklos Szeredi <mszeredi@suse.cz>
Wed, 2 Apr 2014 13:38:48 +0000 (2 15:38 +0200)
treecbc990b308b9894eba032101db994b05e75ad444
parent8373200b124d03de7fa2e99be56de8642e604e9e
fuse: Trust kernel i_mtime only

Let the kernel maintain i_mtime locally:
 - clear S_NOCMTIME
 - implement i_op->update_time()
 - flush mtime on fsync and last close
 - update i_mtime explicitly on truncate and fallocate

Fuse inode flag FUSE_I_MTIME_DIRTY serves as indication that local i_mtime
should be flushed to the server eventually.

Signed-off-by: Maxim Patlasov <MPatlasov@parallels.com>
Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
fs/fuse/dir.c
fs/fuse/file.c
fs/fuse/fuse_i.h
fs/fuse/inode.c