From: Federico Vaga <federico.vaga@gmail.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] base/core.c: improve comment of the function device_find_child()
Date: Mon, 15 Apr 2013 10:32:16 +0200 [thread overview]
Message-ID: <2118225.n4e7fofQ54@harkonnen> (raw)
In-Reply-To: <20130412215125.GA16042@kroah.com>
On Friday 12 April 2013 14:51:25 Greg Kroah-Hartman wrote:
> On Fri, Apr 12, 2013 at 01:59:32PM +0200, Federico Vaga wrote:
> > Signed-off-by: Federico Vaga <federico.vaga@gmail.com>
> > ---
> >
> > drivers/base/core.c | 4 ++++
> > 1 file changed, 4 insertions(+)
> >
> > diff --git a/drivers/base/core.c b/drivers/base/core.c
> > index 016312437..eb0c6ea 100644
> > --- a/drivers/base/core.c
> > +++ b/drivers/base/core.c
> > @@ -1372,6 +1372,10 @@ int device_for_each_child(struct device *parent,
> > void *data,>
> > * if it does. If the callback returns non-zero and a reference to the
> > * current device can be obtained, this function will return to the
> > caller
> > * and not iterate over any more devices.
> >
> > + *
> > + * NOTE: internally, the function does get_device() on the retrieved
> > child. + * It is duty of the caller performing a put_device() on the
> > retrieved + * child device when the caller finishes to work on it.
> >
> > */
>
> Why not just use the same wording that class_find_device() has, which is
> simpler and easier to understand (IMHO)?
Mh, yes. You are right. I'll send a new patch
--
Federico Vaga
prev parent reply other threads:[~2013-04-15 8:32 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-12 11:59 [PATCH] base/core.c: improve comment of the function device_find_child() Federico Vaga
2013-04-12 21:51 ` Greg Kroah-Hartman
2013-04-15 8:32 ` Federico Vaga [this message]
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=2118225.n4e7fofQ54@harkonnen \
--to=federico.vaga@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
/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