[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20080526192914.31045d09@brian.englab.brq.redhat.com>
Date: Mon, 26 May 2008 19:29:14 +0200
From: Michal Schmidt <mschmidt@...hat.com>
To: Daniel Walker <dwalker@...sta.com>
Cc: linville@...driver.com, rusty@...tcorp.com.au, matthew@....cx,
mingo@...e.hu, linux-kernel@...r.kernel.org,
linux-wireless@...r.kernel.org, arjan@...radead.org
Subject: Re: [PATCH] net: wireless: airo semaphore to mutex
On Thu, 22 May 2008 16:21:03 -0700
Daniel Walker <dwalker@...sta.com> wrote:
> Signed-off-by: Daniel Walker <dwalker@...sta.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.
Michal
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists