From: Aneesh Kumar K.V Date: Wed, 23 Mar 2011 14:18:16 +0000 (+0530) Subject: fs/9p: Fix revalidate to return correct value X-Git-Tag: upstream/snapshot3+hdmi~10627^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f2eda2c6cc138710ae775490397657e8877774b6;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git fs/9p: Fix revalidate to return correct value revalidate should return > 0 on success. Also return 0 on ENOENT to force do_revalidate to return NULL dentry; Signed-off-by: Aneesh Kumar K.V Signed-off-by: Venkateswararao Jujjuri Signed-off-by: Eric Van Hensbergen --- diff --git a/fs/9p/vfs_dentry.c b/fs/9p/vfs_dentry.c index b6a3b9f..e022890 100644 --- a/fs/9p/vfs_dentry.c +++ b/fs/9p/vfs_dentry.c @@ -126,7 +126,9 @@ static int v9fs_lookup_revalidate(struct dentry *dentry, struct nameidata *nd) retval = v9fs_refresh_inode_dotl(fid, inode); else retval = v9fs_refresh_inode(fid, inode); - if (retval <= 0) + if (retval == -ENOENT) + return 0; + if (retval < 0) return retval; } out_valid: