Linux wireless drivers development
 help / color / mirror / Atom feed
From: Daniel Walker <dwalker@mvista.com>
To: Michal Schmidt <mschmidt@redhat.com>
Cc: linville@tuxdriver.com, rusty@rustcorp.com.au, matthew@wil.cx,
	mingo@elte.hu, linux-kernel@vger.kernel.org,
	linux-wireless@vger.kernel.org, arjan@infradead.org
Subject: Re: [PATCH] net: wireless: airo semaphore to mutex
Date: Mon, 26 May 2008 10:59:23 -0700	[thread overview]
Message-ID: <1211824763.18130.234.camel@localhost.localdomain> (raw)
In-Reply-To: <20080526192914.31045d09@brian.englab.brq.redhat.com>


On Mon, 2008-05-26 at 19:29 +0200, Michal Schmidt wrote:
> On Thu, 22 May 2008 16:21:03 -0700
> Daniel Walker <dwalker@mvista.com> wrote:
> 
> > Signed-off-by: Daniel Walker <dwalker@mvista.com>
> >  
> > ---
> >  drivers/net/wireless/airo.c |  107
> > ++++++++++++++++++++++---------------------- 1 file changed, 54
> > insertions(+), 53 deletions(-)
> > 
> > Index: linux-2.6.25/drivers/net/wireless/airo.c
> > ===================================================================
> > --- linux-2.6.25.orig/drivers/net/wireless/airo.c
> > +++ linux-2.6.25/drivers/net/wireless/airo.c
> 
> > @@ -3211,7 +3212,7 @@ static irqreturn_t airo_interrupt(int ir
> >  				set_bit(FLAG_UPDATE_UNI,
> > &apriv->flags); set_bit(FLAG_UPDATE_MULTI, &apriv->flags);
> >  
> > -				if (down_trylock(&apriv->sem) != 0) {
> > +				if (mutex_trylock(&apriv->lock) ==
> > 0) { set_bit(JOB_EVENT, &apriv->jobs);
> >  					wake_up_interruptible(&apriv->thr_wait);
> >  				} else
> 
> 
> Mutexes are not allowed in interrupt context, not even mutex_trylock.

I know .. I must have missed that it was in ISR .. Thanks for noticing
it.

Daniel


  reply	other threads:[~2008-05-26 17:59 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-22 23:21 [PATCH] net: wireless: airo semaphore to mutex Daniel Walker
2008-05-26 17:29 ` Michal Schmidt
2008-05-26 17:59   ` Daniel Walker [this message]
2008-05-27  1:17   ` Rusty Russell
2008-05-27  2:15     ` Matthew Wilcox
2008-05-27  4:34       ` Daniel Walker
2008-05-27 11:24         ` Matthew Wilcox
2008-05-27  4:37       ` Rusty Russell
2008-05-27 13:13 ` Matthew Wilcox
2008-05-27 13:48   ` Dan Williams
2008-05-27 15:08     ` Daniel Walker
2008-05-27 15:34       ` Matthew Wilcox
2008-05-27 16:01         ` Daniel Walker

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=1211824763.18130.234.camel@localhost.localdomain \
    --to=dwalker@mvista.com \
    --cc=arjan@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=matthew@wil.cx \
    --cc=mingo@elte.hu \
    --cc=mschmidt@redhat.com \
    --cc=rusty@rustcorp.com.au \
    /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