]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - fs/autofs4/root.c
[PATCH] autofs4: bad lookup fix
[linux-2.6-omap-h63xx.git] / fs / autofs4 / root.c
index e137acf0543dffb931c83d04d4cac1ee5f83461b..2a771ec66956f92615de35694dc512f0144aedba 100644 (file)
@@ -306,7 +306,14 @@ static int try_to_fill_dentry(struct dentry *dentry,
                
                DPRINTK("expire done status=%d", status);
                
-               return 0;
+               /*
+                * If the directory still exists the mount request must
+                * continue otherwise it can't be followed at the right
+                * time during the walk.
+                */
+               status = d_invalidate(dentry);
+               if (status != -EBUSY)
+                       return 0;
        }
 
        DPRINTK("dentry=%p %.*s ino=%p",