From owner-freebsd-current@FreeBSD.ORG Sat Aug 22 16:43:50 2009 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 57B43106568B for ; Sat, 22 Aug 2009 16:43:50 +0000 (UTC) (envelope-from sam@errno.com) Received: from ebb.errno.com (ebb.errno.com [69.12.149.25]) by mx1.freebsd.org (Postfix) with ESMTP id 0C6C58FC12 for ; Sat, 22 Aug 2009 16:43:49 +0000 (UTC) Received: from ice.local ([10.0.0.115]) (authenticated bits=0) by ebb.errno.com (8.13.6/8.12.6) with ESMTP id n7MGhm12049522 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 22 Aug 2009 09:43:49 -0700 (PDT) (envelope-from sam@errno.com) Message-ID: <4A902044.1010200@errno.com> Date: Sat, 22 Aug 2009 09:43:48 -0700 From: Sam Leffler User-Agent: Thunderbird 2.0.0.23 (Macintosh/20090812) MIME-Version: 1.0 To: current@freebsd.org References: <20090821074506.GT70474@acme.spoerlein.net> <20090821103139.66925eb3@vlado.suse.cz> <20090821183806.GG91417@acme.spoerlein.net> In-Reply-To: <20090821183806.GG91417@acme.spoerlein.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-DCC-sonic.net-Metrics: ebb.errno.com; whitelist Cc: Vladimir Botka Subject: Re: [regression] iwi0 with WPA on 8.0 - FIXED, pilot error X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Aug 2009 16:43:50 -0000 Ulrich Spörlein wrote: > On Fri, 21.08.2009 at 10:31:39 +0200, Vladimir Botka wrote: >> It seems that there is no problem with WPA. The wpa_supplicant >> associates. You can see the message. >> >> wpa_supplicant[481]: Associated with 00:21:27:f3:37:37 >> >> Run the wpa_supplicant with more debug info to get more information why >> the wpa_supplicant disconnects later. >> >> wpa_supplicant[481]: CTRL-EVENT-DISCONNECTED - Disconnect > > It is a combination of setting the MAC address that makes wpa_supplicant > barf. These settings in rc.conf result in broken wpa_supplicant during > boot: > > ifconfig_bfe0="up" > ifconfig_iwi0="up" > wlans_iwi0="wlan0" > ifconfig_wlan0="WPA ether 00:0f:1f:1d:a3:76 ssid COYOTE" > cloned_interfaces="lagg0" > ifconfig_lagg0="DHCP up laggproto failover laggport bfe0 laggport wlan0" > > Result > > iwi0: timeout waiting for (null) firmware initialization to complete > iwi0: could not load boot firmware (null) > iwi0: timeout waiting for (null) firmware initialization to complete > iwi0: could not load boot firmware (null) > wlan0: Ethernet address: 00:15:00:22:26:61 > iwi0: need multicast update callback > iwi0: need multicast update callback > iwi0: need multicast update callback > wlan0: link state changed to DOWN > wlan0: link state changed to UP > wlan0: link state changed to DOWN > wlan0: link state changed to UP > wlan0: link state changed to DOWN > wlan0: link state changed to UP > wlan0: link state changed to DOWN > > As you can see, wlan0 is created with the wrong MAC address and > wpa_supplicant does not like different MACs on the wlanX dev and the > real hardware. > > These settings now work. Everything is well > > ifconfig_bfe0="up" > ifconfig_iwi0="ether 00:0f:1f:1d:a3:76 up" > wlans_iwi0="wlan0" > ifconfig_wlan0="WPA ssid COYOTE" > cloned_interfaces="lagg0" > ifconfig_lagg0="DHCP up laggproto failover laggport bfe0 laggport wlan0" It so happens I've been discussing this issue with someone else. The lagg setup is documented in the EXAMPLES section of lagg(4) and doing things this way will be necessary for 8.0. Changing the mac address of a vap after it is created does not work right and may never work for certain devices. There are issues in how the ifnet layer handles this operation and when there are multiple vap's present it is unclear how to handle this operation (if it's possible at all). Devices like iwn that do not support multi-bssid can handle dynamically changing the mac address but not w/o some changes to the infrastructure. For now you need to force the mac address of the underlying device so cloned ifnet's inherit the new address. Sam