diff -ruNp a/fs/ecryptfs/file.c b/fs/ecryptfs/file.c --- a/fs/ecryptfs/file.c 2009-07-20 05:39:19.000000000 +0200 +++ b/fs/ecryptfs/file.c 2009-09-05 01:20:11.000000000 +0200 @@ -62,8 +62,15 @@ static ssize_t ecryptfs_read_update_atim if (rc >= 0) { lower_dentry = ecryptfs_dentry_to_lower(file->f_path.dentry); lower_vfsmount = ecryptfs_dentry_to_lower_mnt(file->f_path.dentry); + if (lower_dentry->d_inode == NULL) { + struct inode *l_inode = file->f_mapping->host; + if (!l_inode && IS_ERR(l_inode)) + goto out; + d_instantiate(lower_dentry, l_inode); + } touch_atime(lower_vfsmount, lower_dentry); } +out: return rc; }