public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Vamsi Krishna S ." <vamsi@in.ibm.com>
To: William Lee Irwin III <wli@holomorphy.com>,
	Stephen Hemminger <shemminger@osdl.org>,
	Kernel List <linux-kernel@vger.kernel.org>,
	lkcd-devel@lists.sourceforge.net, ak@suse.de,
	cminyard@mvista.com, vamsi_krishna@in.ibm.com
Subject: Re: [PATCH] Notifier for significant events on i386
Date: Wed, 11 Dec 2002 17:13:37 +0530	[thread overview]
Message-ID: <20021211171337.A17600@in.ibm.com> (raw)
In-Reply-To: <20021211111639.GJ9882@holomorphy.com>; from wli@holomorphy.com on Wed, Dec 11, 2002 at 03:16:39AM -0800

On Wed, Dec 11, 2002 at 03:16:39AM -0800, William Lee Irwin III wrote:
> On Wed, Dec 11, 2002 at 04:51:53PM +0530, Vamsi Krishna S . wrote:
> > <snip>
> >
> > I am considering using a RCU-based list for notifier chains.
> > Corey has done some work on these lines to add NMI notifier
> > chain, I think it should be generalised on for all notifiers.
> 
> A coherent explanation of how notifier locking is supposed to work
> would be wonderful to have. I'd like to register notifiers but am
> pig ignorant of how to lock my structures down to work with it.
> 
Unless I am missing something, notifiers have always been racy. 
No amount of locking you do in individual modules to prevent
races will help as the notifier chain is walked inside 
notifier_call_chain() in kernel/sys.c. One would need to
add some form of locking there (*) so that users of notifier
chains need not worry about races/locking at all.

(*) converting the notifier chain to an RCU-based list guarentees
to modules using the notifier chains that their handlers will
not be called once the handler is unregistered.

> Bill
Vamsi.
-- 
Vamsi Krishna S.
Linux Technology Center,
IBM Software Lab, Bangalore.
Ph: +91 80 5044959
Internet: vamsi@in.ibm.com

  reply	other threads:[~2002-12-11 11:21 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-12-09 22:02 [PATCH] Notifier for significant events on i386 Stephen Hemminger
2002-12-11 11:21 ` Vamsi Krishna S .
2002-12-11 11:16   ` William Lee Irwin III
2002-12-11 11:43     ` Vamsi Krishna S . [this message]
2002-12-11 16:56       ` [lkcd-devel] " Stephen Hemminger
2002-12-11 20:27       ` John Levon
2002-12-11 21:15         ` Alan Cox
2002-12-12  0:19           ` Stephen Hemminger
2002-12-12  7:34             ` Vamsi Krishna S .
2002-12-12 17:53               ` Stephen Hemminger
2002-12-12 17:58                 ` John Levon
2002-12-13 12:32                   ` Vamsi Krishna S .
2002-12-12  8:13           ` Vamsi Krishna S .
2002-12-11 13:57   ` Corey Minyard

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=20021211171337.A17600@in.ibm.com \
    --to=vamsi@in.ibm.com \
    --cc=ak@suse.de \
    --cc=cminyard@mvista.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkcd-devel@lists.sourceforge.net \
    --cc=shemminger@osdl.org \
    --cc=vamsi_krishna@in.ibm.com \
    --cc=wli@holomorphy.com \
    /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