From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com ([209.132.183.28]:60656 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726226AbeIWCOt (ORCPT ); Sat, 22 Sep 2018 22:14:49 -0400 From: Frank Sorenson To: linux-fsdevel@vger.kernel.org Cc: hirofumi@mail.parknet.co.jp Subject: [PATCH V3 0/4] fat: timestamp updates Date: Sat, 22 Sep 2018 15:19:55 -0500 Message-Id: <20180922201959.10477-1-sorenson@redhat.com> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: vfat/msdos timestamps are stored on-disk with several different granularities, some of them lower resolution than timespec_trunc() can provide. In addition, they are only truncated as they are written to disk, so the timestamps in-memory for new or modified files/directories may be different from the same timestamps after a remount, as the now-truncated times are re-read from the on-disk format. These patches allow finer granularity for the timestamps where possible and add fat-specific ->update_time inode operation and fat_truncate_time functions to truncate each timestamp correctly, giving consistent times across remounts. Frank Sorenson (4): fat: set the s_time_gran for msdos or vfat mounts fat: create function to calculate timezone offset fat: add functions to update and truncate the timestamps appropriately fat: change timestamp updates to fat_update_time or fat_truncate_time fs/fat/dir.c | 2 +- fs/fat/fat.h | 14 ++++++++++ fs/fat/file.c | 18 ++++++++++--- fs/fat/inode.c | 6 ++--- fs/fat/misc.c | 74 +++++++++++++++++++++++++++++++++++++++++++++------- fs/fat/namei_msdos.c | 17 ++++++------ fs/fat/namei_vfat.c | 15 ++++++----- 7 files changed, 114 insertions(+), 32 deletions(-) -- 2.13.6