linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [patch 7/9] wl1271: add missing spin_lock()
@ 2010-05-08 16:25 Dan Carpenter
  2010-05-11  4:27 ` Luciano Coelho
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2010-05-08 16:25 UTC (permalink / raw)
  To: Luciano Coelho
  Cc: John W. Linville, Juuso Oikarinen, Teemu Paasikivi, Kalle Valo,
	linux-wireless

We should start the loop consistently with the "wl_lock" lock held.

Signed-off-by: Dan Carpenter <error27@gmail.com>

diff --git a/drivers/net/wireless/wl12xx/wl1271_main.c b/drivers/net/wireless/wl12xx/wl1271_main.c
index 3e4b9fb..b61cd10 100644
--- a/drivers/net/wireless/wl12xx/wl1271_main.c
+++ b/drivers/net/wireless/wl12xx/wl1271_main.c
@@ -466,6 +466,7 @@ static void wl1271_irq_work(struct work_struct *work)
 		intr = le32_to_cpu(wl->fw_status->intr);
 		if (!intr) {
 			wl1271_debug(DEBUG_IRQ, "Zero interrupt received.");
+			spin_lock_irqsave(&wl->wl_lock, flags);
 			continue;
 		}
 

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [patch 7/9] wl1271: add missing spin_lock()
  2010-05-08 16:25 [patch 7/9] wl1271: add missing spin_lock() Dan Carpenter
@ 2010-05-11  4:27 ` Luciano Coelho
  0 siblings, 0 replies; 2+ messages in thread
From: Luciano Coelho @ 2010-05-11  4:27 UTC (permalink / raw)
  To: ext Dan Carpenter
  Cc: John W. Linville, Oikarinen Juuso (Nokia-D/Tampere),
	Paasikivi Teemu.3 (EXT-Ixonos/Tampere), Kalle Valo,
	linux-wireless@vger.kernel.org

On Sat, 2010-05-08 at 18:25 +0200, ext Dan Carpenter wrote:
> We should start the loop consistently with the "wl_lock" lock held.
> 
> Signed-off-by: Dan Carpenter <error27@gmail.com>
> 
> diff --git a/drivers/net/wireless/wl12xx/wl1271_main.c b/drivers/net/wireless/wl12xx/wl1271_main.c
> index 3e4b9fb..b61cd10 100644
> --- a/drivers/net/wireless/wl12xx/wl1271_main.c
> +++ b/drivers/net/wireless/wl12xx/wl1271_main.c
> @@ -466,6 +466,7 @@ static void wl1271_irq_work(struct work_struct *work)
>  		intr = le32_to_cpu(wl->fw_status->intr);
>  		if (!intr) {
>  			wl1271_debug(DEBUG_IRQ, "Zero interrupt received.");
> +			spin_lock_irqsave(&wl->wl_lock, flags);
>  			continue;
>  		}
>  

Good catch.  Thank you.

Acked-by: Luciano Coelho <luciano.coelho@nokia.com>


-- 
Cheers,
Luca.



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-05-11  4:27 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-08 16:25 [patch 7/9] wl1271: add missing spin_lock() Dan Carpenter
2010-05-11  4:27 ` Luciano Coelho

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).