[OpenAFS] file timestamp difference

Jim Rees rees@umich.edu
Wed, 24 Oct 2007 13:59:09 -0400


Here's an interesting nugget from LINUX/osi_vfsops.c:vattr2inode():

#if defined(AFS_LINUX26_ENV)
    ip->i_atime.tv_sec = vp->va_atime.tv_sec;
    ip->i_mtime.tv_sec = vp->va_mtime.tv_sec;
    /* Set the mtime nanoseconds to the sysname generation number.
     * This convinces NFS clients that all directories have changed
     * any time the sysname list changes.
     */
    ip->i_mtime.tv_nsec = afs_sysnamegen;
    ip->i_ctime.tv_sec = vp->va_ctime.tv_sec;
#else

Seems like a bug to me.  This should be:

#if defined(AFS_LINUX26_ENV)
    ip->i_atime = vp->va_atime;
    ip->i_mtime = vp->va_mtime;
    ip->i_ctime = vp->va_ctime;
#else

What do you get from "ls -rtlc --full-time *"?