From owner-freebsd-wireless@FreeBSD.ORG Sat Nov 2 06:50:22 2013 Return-Path: Delivered-To: freebsd-wireless@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id D19B3945 for ; Sat, 2 Nov 2013 06:50:22 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-qa0-x230.google.com (mail-qa0-x230.google.com [IPv6:2607:f8b0:400d:c00::230]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 91F8924AE for ; Sat, 2 Nov 2013 06:50:22 +0000 (UTC) Received: by mail-qa0-f48.google.com with SMTP id k4so1083140qaq.14 for ; Fri, 01 Nov 2013 23:50:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=oDxnoCtp/CKWV5zllnHhdE8stNy9UztXr45ByD9G5xA=; b=vk8xTPNpCihMc6NqnzzDT1JlsiNau4UdGDhWdWD+4wc5Q9uzghrJUMK3JJtsgVpx5Z 8eV74EqgECwpgBBGPCwF5cnSZTOKr4wrnfyfPp2t9S3OeW15RY0BjukFLOSRcls/Ul8/ q6LHqoZK5MKBHMUApGSscQ+cfHc16pI9k42Ik+fVoNWtPYY/f3Y2AE5Dq497aU1uQ3Ws rlkeozFM1pnPQDqSos97qpJTJJk8tZJGtpcahSNgn6S3fVGHDBZiAx3RQ1e2ZZScIXKx j54J7E/5Xhz9rLT5wBxMaakxDWz3nF2BBtPgnTnb5CHj3vxTNntR4bg2zUjg3HghRUeV lc2A== MIME-Version: 1.0 X-Received: by 10.49.24.202 with SMTP id w10mr8846650qef.12.1383375021823; Fri, 01 Nov 2013 23:50:21 -0700 (PDT) Received: by 10.224.207.66 with HTTP; Fri, 1 Nov 2013 23:50:21 -0700 (PDT) In-Reply-To: <1383338117.13657.53.camel@eva02.mbsd> References: <1382572583.1862.39.camel@eva02.mbsd> <1382589020.1846.36.camel@eva02.mbsd> <1383331203.12614.1.camel@eva02.mbsd> <1383336004.13657.18.camel@eva02.mbsd> <1383338117.13657.53.camel@eva02.mbsd> Date: Fri, 1 Nov 2013 23:50:21 -0700 Message-ID: Subject: Re: service netif restart [iface] runs a wpa_supplicant twice From: Adrian Chadd To: clutton Content-Type: text/plain; charset=ISO-8859-1 Cc: "freebsd-wireless@freebsd.org" X-BeenThere: freebsd-wireless@freebsd.org X-Mailman-Version: 2.1.14 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: Sat, 02 Nov 2013 06:50:23 -0000 OK, so where's the other path for invoking wpa_supplicant? -a On 1 November 2013 13:35, clutton wrote: > On Fri, 2013-11-01 at 13:02 -0700, Adrian Chadd wrote: >> What's running the other copy? >> >> >> >> Adrian >> >> On Nov 1, 2013 4:00 PM, "clutton" wrote: >> On Fri, 2013-11-01 at 12:33 -0700, Adrian Chadd wrote: >> > On 1 November 2013 12:16, Bernhard Schmidt >> wrote: >> > >> > > That actually is a design question I once wrapped my head >> around >> > > unsuccessfully. The lines above are responsible for >> configuring wlan0 >> > > if it is created, eg. >> > > ifconfig wlan0 destroy >> > > ifconfig wlan0 create wlandev ath0 >> > > will invoke above code which will then invoke >> pccard_ether. Changing >> > > the code as you intent to will prevent this. >> > > >> > > Someone should step up an decide what is supposed to >> happen, should >> > > wlan0 in that case be configured as stated in rc.conf, or >> not? >> > > >> > > The actual issue though, is in wpa_supplicant itself. It >> has code to >> > > prevent it being started twice, but that doesn't kick in >> because the >> > > instances are started to fast and we loose (have not yet >> setup enough) >> > > information in our net code. >> > >> > Uhm, I'm confused by this. Would you mind explaining it in a >> bit more detail? >> > >> > >> > -a >> >> The devd runs a pccard_ether script when the IFNET interface >> appears. >> In some rare cases you can see two copies of the >> wpa_sopplicant. > > devd: > > notify 0 { > match "system" "IFNET"; > match "subsystem" "!usbus[0-9]+"; > match "type" "ATTACH"; > action "/etc/pccard_ether $subsystem start"; > }; >