summaryrefslogtreecommitdiffstats
path: root/fs/cifs
diff options
context:
space:
mode:
authorGerlando Falauto <gerlando.falauto@keymile.com>2011-10-18 10:58:50 +0200
committerSteve French <smfrench@gmail.com>2011-10-18 10:49:38 -0500
commitad4778fb40994dd7c779069dad6ff704d75b81e6 (patch)
tree10fa342478770437160177d81bed2a797f2be18e /fs/cifs
parent7748dd6eab8e13f974d4664395e76afffacda04b (diff)
downloadop-kernel-dev-ad4778fb40994dd7c779069dad6ff704d75b81e6.zip
op-kernel-dev-ad4778fb40994dd7c779069dad6ff704d75b81e6.tar.gz
CIFS: fix automount for DFS shares
Automounting directories are now invalidated by .d_revalidate() so to be d_instantiate()d again with the right DCACHE_NEED_AUTOMOUNT flag Reviewed-by: Jeff Layton <jlayton@samba.org> Signed-off-by: Gerlando Falauto <gerlando.falauto@keymile.com> Signed-off-by: Steve French <smfrench@gmail.com>
Diffstat (limited to 'fs/cifs')
-rw-r--r--fs/cifs/dir.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/fs/cifs/dir.c b/fs/cifs/dir.c
index 0c8098d..d7eeb9d 100644
--- a/fs/cifs/dir.c
+++ b/fs/cifs/dir.c
@@ -648,8 +648,16 @@ cifs_d_revalidate(struct dentry *direntry, struct nameidata *nd)
if (direntry->d_inode) {
if (cifs_revalidate_dentry(direntry))
return 0;
- else
+ else {
+ /*
+ * Forcibly invalidate automounting directory inodes
+ * (remote DFS directories) so to have them
+ * instantiated again for automount
+ */
+ if (IS_AUTOMOUNT(direntry->d_inode))
+ return 0;
return 1;
+ }
}
/*
OpenPOWER on IntegriCloud