public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Paul Bolle <pebolle@tiscali.nl>
To: "Robert P. J. Day" <rpjday@crashcourse.ca>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Randy Dunlap <rdunlap@xenotime.net>
Subject: Re: [PATCH] DOCUMENTATION: Correct inline docs to match parm name.
Date: Tue, 30 Nov 2010 14:19:29 +0100	[thread overview]
Message-ID: <1291123175.1992.7.camel@localhost.localdomain> (raw)
In-Reply-To: <alpine.DEB.2.00.1011300629580.21294@localhost6.localdomain6>

On Tue, 2010-11-30 at 06:31 -0500, Robert P. J. Day wrote:
> @@ -1485,7 +1485,7 @@ out:
>  /**
>   * d_validate - verify dentry provided from insecure source
>   * @dentry: The dentry alleged to be valid child of @dparent

Doesn't this one needs to be changed too?

> - * @dparent: The parent dentry (known to be valid)
> + * @parent: The parent dentry (known to be valid)
>   *
>   * An insecure source has sent us a dentry, here we verify it and dget() it.
>   * This is used by ncpfs in its readdir implementation.

By the way, the code currently reads:

int d_validate(struct dentry *dentry, struct dentry *parent)
{
[...]
        rcu_read_lock();
        hlist_for_each_entry_rcu(d, node, head, d_hash) {
                if (d == dentry) {
                        dget(dentry);
                        return 1;
                }
        }
        rcu_read_unlock();
        return 0;
}

I know nothing about rcu_read_lock(), but why is there no
rcu_read_unlock() before the "return 1" case?


Paul Bolle


  reply	other threads:[~2010-11-30 13:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-30 11:31 [PATCH] DOCUMENTATION: Correct inline docs to match parm name Robert P. J. Day
2010-11-30 13:19 ` Paul Bolle [this message]
2010-11-30 16:39 ` Randy Dunlap

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=1291123175.1992.7.camel@localhost.localdomain \
    --to=pebolle@tiscali.nl \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rdunlap@xenotime.net \
    --cc=rpjday@crashcourse.ca \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox