• Marc Dionne's avatar
    afs: Set mtime from the client for yfs create operations · 52af7105
    Marc Dionne authored
    For operations that create vnodes on the server such as CreateFile,
    MakeDir or Symlink, the server will store its own current time as
    the mtime if the client doesn't pass in a time in the accompanying
    StoreStatus structure.
    
    If the server and client clocks are not well synchronized, the client
    may see timestamps in the future or inconsistent dependency checks
    with "make" for files that are not modified after creation:
    
    make[2]: Warning: File 'arch/x86/kernel/apic/modules.order' has
    modification time 0.14 s in the future
    make[2]: warning:  Clock skew detected.  Your build may be incomplete.
    
    This is already handled correctly for non yfs operations; also
    set the mtime for the corresponding yfs operations.
    
    Changes:
    v3: Replace S_IRWXUGO with 0777, per checkpatch
    v2: [dhowells] Merge the two xdr_encode_YFSStoreStatus*() functions together
    Signed-off-by: default avatarMarc Dionne <marc.dionne@auristor.com>
    Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
    Link: http://lists.infradead.org/pipermail/linux-afs/2021-October/004395.html
    52af7105
yfsclient.c 47.4 KB