From: Dan Williams <dcbw@redhat.com>
To: Holger Schurig <hs4233@mail.mn-solutions.de>
Cc: libertas-dev@lists.infradead.org, linux-wireless@vger.kernel.org,
"John W. Linville" <linville@tuxdriver.com>
Subject: Re: [PATCH] libertas: fix spinlock recursion bug
Date: Wed, 19 Mar 2008 11:02:46 -0400 [thread overview]
Message-ID: <1205938966.26119.37.camel@localhost.localdomain> (raw)
In-Reply-To: <200803191524.21866.hs4233@mail.mn-solutions.de>
On Wed, 2008-03-19 at 15:24 +0100, Holger Schurig wrote:
> This fixes a bug detected by CONFIG_DEBUG_SPINLOCK:
>
> if_cs_get_int_status() is only called from lbs_thread(), via
> priv->hw_get_int_status. However, lbs_thread() has already taken the
> priv->driver_lock. So it's a fault to take the same lock again here.
>
> Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Acked-by: Dan Williams <dcbw@redhat.com>
> CONFIG_DEBUG_SPINLOCK,
> ---
>
> John, this patch might also go into linux-2.6.25-rcX
>
> Index: wireless-testing/drivers/net/wireless/libertas/if_cs.c
> ===================================================================
> --- wireless-testing.orig/drivers/net/wireless/libertas/if_cs.c 2008-03-19 13:46:47.000000000 +0100
> +++ wireless-testing/drivers/net/wireless/libertas/if_cs.c 2008-03-19 13:46:53.000000000 +0100
> @@ -677,9 +677,7 @@ sbi_get_int_status_exit:
>
> /* Card has a command result for us */
> if (*ireg & IF_CS_C_S_CMD_UPLD_RDY) {
> - spin_lock(&priv->driver_lock);
> ret = if_cs_receive_cmdres(priv, priv->upld_buf, &priv->upld_len);
> - spin_unlock(&priv->driver_lock);
> if (ret < 0)
> lbs_pr_err("could not receive cmd from card\n");
> }
next prev parent reply other threads:[~2008-03-19 19:43 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-19 14:24 [PATCH] libertas: fix spinlock recursion bug Holger Schurig
2008-03-19 15:02 ` Dan Williams [this message]
2008-03-26 7:48 ` Holger Schurig
2008-03-26 14:41 ` Holger Schurig
2008-03-26 15:17 ` Dan Williams
2008-03-26 15:37 ` Holger Schurig
2008-03-26 17:33 ` Dan Williams
2008-03-27 8:17 ` Holger Schurig
2008-03-27 10:08 ` Holger Schurig
2008-03-27 11:34 ` Dan Williams
2008-03-27 11:57 ` Holger Schurig
2008-03-27 14:31 ` Dan Williams
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=1205938966.26119.37.camel@localhost.localdomain \
--to=dcbw@redhat.com \
--cc=hs4233@mail.mn-solutions.de \
--cc=libertas-dev@lists.infradead.org \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.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