linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg KH <greg@kroah.com>
To: Dave Young <hidave.darkstar@gmail.com>
Cc: linux-kernel@vger.kernel.org, Kay Sievers <kay.sievers@vrfy.org>,
	Alan Stern <stern@rowland.harvard.edu>,
	Jonathan Corbet <corbet@lwn.net>,
	Randy Dunlap <randy.dunlap@oracle.com>
Subject: Re: [RFC] kobject/kset/ktype documentation and example code updated
Date: Thu, 20 Dec 2007 00:02:59 -0800	[thread overview]
Message-ID: <20071220080259.GA30416@kroah.com> (raw)
In-Reply-To: <a8e1da0712192354k3bce177fi3d30b5737c7d7a9e@mail.gmail.com>

On Thu, Dec 20, 2007 at 03:54:40PM +0800, Dave Young wrote:
> On Dec 20, 2007 8:30 AM, Greg KH <greg@kroah.com> wrote:
> > Thanks to everyone for your last round of review comments and changes to
> > the kobject documentation.
> >
> > I now have over 130 patches reworking the kset/ktype and kobject apis in
> > the kernel tree, and here is the updated documentation and example code
> > that shows how things work now.
> >
> > Things different from the last time around are the kobject_add() and
> > kobject_init() functions now take a bunch of required parameters, and
> > the kobject cleanup code is much more forgiving.
> >
> > I want to drop kobject_unregister() but as this patch series is so big
> > already, I think it's time to let it bake in -mm and push into 2.6.25
> > before attempting it.
> [--snip--]
> 
> Hi, greg
> 
> How about add a kobject_remove function and temporarily keep the
> kobject_unregister as below until the 2.6.25:
> 
> kobject_unregister(...)
> {
>        ...
>         kobject_remove();
>         kobject_uevent();
>         ...
> }

Actually, it's not needed at all.  Thanks to Kay's recent changes in the
tree, a simple kobject_put() is all that is needed.  The proper sysfs
cleanup and uevent will happen if necessary, no housekeeping by the
caller required.

So I'll just nuke kobject_unregister() as it's a simple replacement with
kobject_put() which will clean up the api even more :)

And I'll go update the documentation...

thanks,

greg k-h

  reply	other threads:[~2007-12-20  8:04 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-20  0:30 [RFC] kobject/kset/ktype documentation and example code updated Greg KH
2007-12-20  0:31 ` [RFC] sample kobject implementation code Greg KH
2007-12-20  0:31 ` [RFC] sample kset/ktype/kobject " Greg KH
2008-01-03 15:14   ` Cornelia Huck
2007-12-20  4:26 ` [RFC] kobject/kset/ktype documentation and example code updated Alan Stern
2007-12-20  7:27   ` Kay Sievers
2007-12-20 21:48   ` Greg KH
2007-12-20  6:32 ` Randy Dunlap
2007-12-20 21:27   ` Greg KH
2007-12-20 22:03     ` Robert P. J. Day
2007-12-20 22:20       ` Greg KH
2007-12-20 22:06     ` Randy Dunlap
2007-12-20 22:12       ` Greg KH
2007-12-20 22:29         ` Randy Dunlap
2007-12-20 22:42           ` Greg KH
2007-12-20 22:48             ` Randy Dunlap
2007-12-20 22:57     ` Alan Stern
2007-12-20  7:54 ` Dave Young
2007-12-20  8:02   ` Greg KH [this message]
2007-12-20  9:04 ` Jan Engelhardt
2007-12-20 21:16   ` Greg KH

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=20071220080259.GA30416@kroah.com \
    --to=greg@kroah.com \
    --cc=corbet@lwn.net \
    --cc=hidave.darkstar@gmail.com \
    --cc=kay.sievers@vrfy.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=randy.dunlap@oracle.com \
    --cc=stern@rowland.harvard.edu \
    /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;
as well as URLs for NNTP newsgroup(s).