From: Ian Kent <raven@themaw.net>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Kernel Mailing List <linux-kernel@vger.kernel.org>,
Andrew Morton <akpm@linux-foundation.org>,
Al Viro <viro@ZenIV.linux.org.uk>
Subject: Re: [PATCH] autofs4-2.6.34-rc1 - fix link_count usage
Date: Mon, 10 May 2010 14:04:47 +0800 [thread overview]
Message-ID: <1273471487.2246.1.camel@localhost> (raw)
In-Reply-To: <20100510051830.10353.31165.stgit@localhost.localdomain>
On Mon, 2010-05-10 at 13:18 +0800, Ian Kent wrote:
Sorry, this isn't right, please ignore it.
Apart from the lack of a Signed-off-by: I hadn't tested against
the current kernel source when I posted.
> Following the commit below in 2.6.34-rc1 autofs direct mounts stop
> working. This is caused by current->link_count being 0 when
> ->follow_link() is called from do_filp_open().
>
> I can't work out why this hasn't been seen before Als patch series.
>
> This patch removes the autofs dependence on current->link_count.
>
> 1f36f774b22a0ceb7dd33eca626746c81a97b6a5 is the first bad commit
> commit 1f36f774b22a0ceb7dd33eca626746c81a97b6a5
> Author: Al Viro <viro@zeniv.linux.org.uk>
> Date: Sat Dec 26 10:56:19 2009 -0500
>
> Switch !O_CREAT case to use of do_last()
>
> ... and now we have all intents crap well localized
>
> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
>
> :040000 040000 53c1effc5b22746bb83cdbc6a419bf898067882d 9606f7275fde188a056fd174aa1d622ac0630893 M fs
> ---
>
> fs/autofs4/root.c | 5 ++---
> 1 files changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/fs/autofs4/root.c b/fs/autofs4/root.c
> index 109a6c6..a7e04ad 100644
> --- a/fs/autofs4/root.c
> +++ b/fs/autofs4/root.c
> @@ -177,8 +177,7 @@ static int try_to_fill_dentry(struct dentry *dentry, int flags)
> }
> /* Trigger mount for path component or follow link */
> } else if (ino->flags & AUTOFS_INF_PENDING ||
> - autofs4_need_mount(flags) ||
> - current->link_count) {
> + autofs4_need_mount(flags)) {
> DPRINTK("waiting for mount name=%.*s",
> dentry->d_name.len, dentry->d_name.name);
>
> @@ -262,7 +261,7 @@ static void *autofs4_follow_link(struct dentry *dentry, struct nameidata *nd)
> spin_unlock(&dcache_lock);
> spin_unlock(&sbi->fs_lock);
>
> - status = try_to_fill_dentry(dentry, 0);
> + status = try_to_fill_dentry(dentry, lookup_type);
> if (status)
> goto out_error;
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
next prev parent reply other threads:[~2010-05-10 6:05 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-10 5:18 [PATCH] autofs4-2.6.34-rc1 - fix link_count usage Ian Kent
2010-05-10 6:04 ` Ian Kent [this message]
-- strict thread matches above, loose matches on Subject: below --
2010-05-10 8:46 Ian Kent
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1273471487.2246.1.camel@localhost \
--to=raven@themaw.net \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@linux-foundation.org \
--cc=viro@ZenIV.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.