diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2000-04-19 04:00:00 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2000-04-19 04:00:00 +0000 |
commit | 46e045034336a2cc90c1798cd7cc07af744ddfd6 (patch) | |
tree | 3b9b51fc482e729f663d25333e77fbed9aaa939a /fs/autofs | |
parent | 31dc59d503a02e84c4de98826452acaeb56dc15a (diff) |
Merge with Linux 2.3.99-pre4.
Diffstat (limited to 'fs/autofs')
-rw-r--r-- | fs/autofs/dirhash.c | 3 | ||||
-rw-r--r-- | fs/autofs/root.c | 6 | ||||
-rw-r--r-- | fs/autofs/symlink.c | 4 |
3 files changed, 6 insertions, 7 deletions
diff --git a/fs/autofs/dirhash.c b/fs/autofs/dirhash.c index d861dc59d..b5626e5bb 100644 --- a/fs/autofs/dirhash.c +++ b/fs/autofs/dirhash.c @@ -78,8 +78,7 @@ struct autofs_dir_ent *autofs_expire(struct super_block *sb, /* Make sure entry is mounted and unused; note that dentry will point to the mounted-on-top root. */ - if ( !S_ISDIR(dentry->d_inode->i_mode) - || dentry->d_mounts == dentry ) { + if (!S_ISDIR(dentry->d_inode->i_mode)||!d_mountpoint(dentry)) { DPRINTK(("autofs: not expirable (not a mounted directory): %s\n", ent->name)); continue; } diff --git a/fs/autofs/root.c b/fs/autofs/root.c index 1540ceda8..06e2e86ea 100644 --- a/fs/autofs/root.c +++ b/fs/autofs/root.c @@ -63,7 +63,7 @@ static int autofs_root_readdir(struct file *filp, void *dirent, filldir_t filldi /* fall through */ default: while ( onr = nr, ent = autofs_hash_enum(dirhash,&nr,ent) ) { - if ( !ent->dentry || ent->dentry->d_mounts != ent->dentry ) { + if ( !ent->dentry || d_mountpoint(ent->dentry) ) { if (filldir(dirent,ent->name,ent->len,onr,ent->ino) < 0) return 0; filp->f_pos = nr; @@ -117,7 +117,7 @@ static int try_to_fill_dentry(struct dentry *dentry, struct super_block *sb, str /* If this is a directory that isn't a mount point, bitch at the daemon and fix it in user space */ - if ( S_ISDIR(dentry->d_inode->i_mode) && dentry->d_mounts == dentry ) { + if ( S_ISDIR(dentry->d_inode->i_mode) && !d_mountpoint(dentry) ) { return !autofs_wait(sbi, &dentry->d_name); } @@ -157,7 +157,7 @@ static int autofs_revalidate(struct dentry * dentry, int flags) return (dentry->d_time - jiffies <= AUTOFS_NEGATIVE_TIMEOUT); /* Check for a non-mountpoint directory */ - if ( S_ISDIR(dentry->d_inode->i_mode) && dentry->d_mounts == dentry ) { + if ( S_ISDIR(dentry->d_inode->i_mode) && !d_mountpoint(dentry) ) { if (autofs_oz_mode(sbi)) return 1; else diff --git a/fs/autofs/symlink.c b/fs/autofs/symlink.c index 129d5917f..3b90a077e 100644 --- a/fs/autofs/symlink.c +++ b/fs/autofs/symlink.c @@ -18,10 +18,10 @@ static int autofs_readlink(struct dentry *dentry, char *buffer, int buflen) return vfs_readlink(dentry, buffer, buflen, s); } -static struct dentry *autofs_follow_link(struct dentry *dentry, struct dentry *base, unsigned flags) +static int autofs_follow_link(struct dentry *dentry, struct nameidata *nd) { char *s=((struct autofs_symlink *)dentry->d_inode->u.generic_ip)->data; - return vfs_follow_link(dentry, base, flags, s); + return vfs_follow_link(nd, s); } struct inode_operations autofs_symlink_inode_operations = { |