Messages in this thread | | | Date | Mon, 28 Dec 1998 14:59:04 -0500 | From | Shantanu Goel <> | Subject | NFS client patch for 2.1.132 |
| |
Hi folks,
The following patch against 2.1.132 does away with redundant GETATTR RPCs by updating the attribute cache when a LOOKUP is performed. This can speed up "ls -Fa" performance quite a bit.
Shantanu ------------------------------------------------------------------------------- *** fs/nfs/dir.c.~1~ Wed Dec 16 15:17:22 1998 --- fs/nfs/dir.c Mon Dec 28 12:21:39 1998 *************** *** 439,444 **** --- 439,456 ---- /* Ok, remeber that we successfully checked it.. */ nfs_renew_times(dentry); + /* + * Duplicate of nfs_revalidate_inode. + */ + error = nfs_refresh_inode(inode, &fattr); + if (error) + goto out_bad; + if (fattr.mtime.seconds == NFS_OLDMTIME(inode)) { + if ((NFS_ATTRTIMEO(inode) <<= 1) > NFS_MAXATTRTIMEO(inode)) + NFS_ATTRTIMEO(inode) = NFS_MAXATTRTIMEO(inode); + } + NFS_OLDMTIME(inode) = fattr.mtime.seconds; + out_valid: return 1; out_bad:
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |