netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Larry Finger <Larry.Finger@lwfinger.net>
To: Maxime Austruy <maxime@tralhalla.org>
Cc: linville@tuxdriver.com, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] softmac: fix unbalanced mutex_lock/unlock in ieee80211softmac_wx_set_mlme
Date: Sun, 03 Dec 2006 10:23:32 -0600	[thread overview]
Message-ID: <4572FA04.6010906@lwfinger.net> (raw)
In-Reply-To: <20061203074203.GB5785@tralhalla.org>

Maxime Austruy wrote:
> Found a hang while playing with wpa_supplicant and a zd1211 usb adapter
> using linux 2.6.19.  The problem is that ieee80211softmac_wx_set_mlme
> forgets to release a mutex when mlme->cmd is IW_MLME_DEAUTH.  The fix
> below allows me to kill wpa_supplicant and to restart it without having
> to reboot the machine. FWIW, it seems that the problem was introduced
> between 2.6.19-rc2 and 2.6.19-rc3 when this function was changed to use
> a mutex.
> 
> Signed-off-by: Maxime Austruy <maxime@tralhalla.org>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
> 
> --
>  net/ieee80211/softmac/ieee80211softmac_wx.c |    3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> --- linux.orig/net/ieee80211/softmac/ieee80211softmac_wx.c	2006-11-29 13:57:37.000000000 -0800
> +++ linux/net/ieee80211/softmac/ieee80211softmac_wx.c	2006-12-02 22:58:20.000000000 -0800
> @@ -495,7 +495,8 @@ ieee80211softmac_wx_set_mlme(struct net_
>  			printk(KERN_DEBUG PFX "wx_set_mlme: we should know the net here...\n");
>  			goto out;
>  		}
> -		return ieee80211softmac_deauth_req(mac, net, reason);
> +		err =  ieee80211softmac_deauth_req(mac, net, reason);
> +		goto out;
>  	case IW_MLME_DISASSOC:
>  		ieee80211softmac_send_disassoc_req(mac, reason);
>  		mac->associnfo.associated = 0;
> -
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 


  reply	other threads:[~2006-12-03 16:23 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-12-03  7:42 [PATCH] softmac: fix unbalanced mutex_lock/unlock in ieee80211softmac_wx_set_mlme Maxime Austruy
2006-12-03 16:23 ` Larry Finger [this message]
  -- strict thread matches above, loose matches on Subject: below --
2006-12-03 16:40 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=4572FA04.6010906@lwfinger.net \
    --to=larry.finger@lwfinger.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=maxime@tralhalla.org \
    --cc=netdev@vger.kernel.org \
    /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).