• Deepa Dinamani's avatar
    fs: nfs: Make nfs boot time y2038 safe · 2f86e091
    Deepa Dinamani authored
    boot_time is represented as a struct timespec.
    struct timespec and CURRENT_TIME are not y2038 safe.
    Overall, the plan is to use timespec64 and ktime_t for
    all internal kernel representation of timestamps.
    CURRENT_TIME will also be removed.
    
    boot_time is used to construct the nfs client boot verifier.
    
    Use ktime_t to represent boot_time and ktime_get_real() for
    the boot_time value.
    
    Following Trond's request https://lkml.org/lkml/2016/6/9/22 ,
    use ktime_t instead of converting to struct timespec64.
    
    Use higher and lower 32 bit parts of ktime_t for the boot
    verifier.
    
    Use the lower 32 bit part of ktime_t for the authsys_parms
    stamp field.
    Signed-off-by: default avatarDeepa Dinamani <deepa.kernel@gmail.com>
    Reviewed-by: default avatarArnd Bergmann <arnd@arndb.de>
    Cc: Trond Myklebust <trond.myklebust@primarydata.com>
    Cc: Anna Schumaker <anna.schumaker@netapp.com>
    Cc: linux-nfs@vger.kernel.org
    Signed-off-by: default avatarAnna Schumaker <Anna.Schumaker@Netapp.com>
    2f86e091
nfs4xdr.c 197 KB