From owner-freebsd-wireless@FreeBSD.ORG Fri Oct 14 04:15:20 2011 Return-Path: Delivered-To: freebsd-wireless@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9A7C7106566B for ; Fri, 14 Oct 2011 04:15:20 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-yw0-f54.google.com (mail-yw0-f54.google.com [209.85.213.54]) by mx1.freebsd.org (Postfix) with ESMTP id 58F648FC14 for ; Fri, 14 Oct 2011 04:15:20 +0000 (UTC) Received: by ywp17 with SMTP id 17so2442040ywp.13 for ; Thu, 13 Oct 2011 21:15:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=qkMEjiff4fsovrnqwWCzhWg1J2npJsXfkSSFxiDDujs=; b=LwU3jjlyJMxShMxAYeZRaPY1EYAqkHqt9pgc0iDhC4QLdcMMC3Nmflcflq217b/Cgs 28e/B585RVYpe01IDXeac8W0KypCXu6KAk6cUSC9ZsAMj8/DNSfuOUKnLxw5DySYUa04 41dqLaZV8/dHtING57bt7HfTLRTIDGg3aK6fY= MIME-Version: 1.0 Received: by 10.236.181.131 with SMTP id l3mr8849395yhm.105.1318565719694; Thu, 13 Oct 2011 21:15:19 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.236.109.167 with HTTP; Thu, 13 Oct 2011 21:15:19 -0700 (PDT) In-Reply-To: <957EB052144AA64AB39F7AB268783201022FA3E653@VA3DIAXVS881.RED001.local> References: <957EB052144AA64AB39F7AB268783201022FA3E653@VA3DIAXVS881.RED001.local> Date: Fri, 14 Oct 2011 12:15:19 +0800 X-Google-Sender-Auth: w072nJrWRA-BeyxHlJtt53YlzgI Message-ID: From: Adrian Chadd To: Edgar Martinez Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: freebsd-wireless@freebsd.org Subject: Re: LOR - COM LOCK X-BeenThere: freebsd-wireless@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Discussions of 802.11 stack, tools device driver development." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Oct 2011 04:15:20 -0000 On 11 October 2011 23:49, Edgar Martinez wrote: > lock order reversal: > =A01st 0xc5912778 ath1_scan_lock (ath1_scan_lock) @ /usr/src/sys/net80211= /ieee80211_node.c:2158 > =A02nd 0xc5911014 ath1_com_lock (ath1_com_lock) @ /usr/src/sys/net80211/i= eee80211_node.c:2510 This is a bit odd. I'm seeing the same LOR. >From what I've determined: * hostap_newstate: the comlock is held, then it calls ieee80211_iterate_nodes(), which grabs the scan/node lock. * ioctl -> ieee80211_ioctl -> ieee80211_iterate_nodes() which grabs the scan/node lock, -> ieee80211_node_leave(), which grabs the comlock. I'm not sure what the correct fix should be and I don't have the time at the moment to fix it. But yes, it should be fixed. Adrian