linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michael Buesch <mb@bu3sch.de>
To: Richard Purdie <rpurdie@openedhand.com>
Cc: Johannes Berg <johannes@sipsolutions.net>,
	linux-wireless <linux-wireless@vger.kernel.org>,
	Larry Finger <Larry.Finger@lwfinger.net>
Subject: Re: b43 problem with led trigger registration
Date: Sun, 16 Dec 2007 21:57:00 +0100	[thread overview]
Message-ID: <200712162157.00759.mb@bu3sch.de> (raw)
In-Reply-To: <1197837799.4653.21.camel@localhost.localdomain>

On Sunday 16 December 2007 21:43:19 Richard Purdie wrote:
> On Sun, 2007-12-16 at 21:38 +0100, Johannes Berg wrote:
> > > > drivers/leds/led-triggers.c:led_trigger_register:
> > > > 
> > > > |        read_lock(&leds_list_lock);
> > > > |        list_for_each_entry(led_cdev, &leds_list, node) {
> > > > |                down_write(&led_cdev->trigger_lock);
> > > > 
> > > > introduced in
> > > > 
> > > > commit dc47206e552c0850ad11f7e9a1fca0a3c92f5d65
> > > > Author: Richard Purdie <rpurdie@rpsys.net>
> > > > Date:   Sat Nov 10 13:29:04 2007 +0000
> > > > 
> > > >     leds: Fix led trigger locking bugs
> > > > 
> > > > I guess the read_lock needs to be a mutex/rw semaphore.
> > > 
> > > Uh, yes. Was this patch tested at all?
> > 
> > Not with default triggers, I guess. The code in question only triggers
> > when a default is assigned to any LED I think.
> 
> Amongst other things it was tested on the Zaurus which has default
> triggers. What is the problem you're seeing?

You are scheduling (down_write) while holding a spinlock (leds_list_lock).

-- 
Greetings Michael.

  parent reply	other threads:[~2007-12-16 20:58 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-16 16:20 b43 problem with led trigger registration Johannes Berg
2007-12-16 17:19 ` Larry Finger
2007-12-16 17:59   ` Johannes Berg
2007-12-16 18:00   ` John W. Linville
2007-12-16 18:50     ` Johannes Berg
2007-12-16 19:36 ` Michael Buesch
2007-12-16 19:59   ` Johannes Berg
2007-12-16 20:26     ` Michael Buesch
2007-12-16 20:38       ` Johannes Berg
2007-12-16 20:43         ` Richard Purdie
2007-12-16 20:46           ` Johannes Berg
2007-12-16 20:57           ` Michael Buesch [this message]
2007-12-16 22:09             ` Richard Purdie
2007-12-16 22:17               ` Johannes Berg
2007-12-16 22:32                 ` Richard Purdie
2007-12-16 22:39                   ` Johannes Berg
2007-12-16 21:00         ` Johannes Berg
2007-12-16 21:16   ` Larry Finger

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=200712162157.00759.mb@bu3sch.de \
    --to=mb@bu3sch.de \
    --cc=Larry.Finger@lwfinger.net \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=rpurdie@openedhand.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;
as well as URLs for NNTP newsgroup(s).