From owner-svn-src-head@FreeBSD.ORG Fri Mar 13 07:12:25 2009 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B2B731065670; Fri, 13 Mar 2009 07:12:25 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 856AB8FC0C; Fri, 13 Mar 2009 07:12:25 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n2D7CP8H055412; Fri, 13 Mar 2009 07:12:25 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n2D7CP1g055409; Fri, 13 Mar 2009 07:12:25 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <200903130712.n2D7CP1g055409@svn.freebsd.org> From: Brooks Davis Date: Fri, 13 Mar 2009 07:12:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r189759 - in head: etc etc/defaults share/man/man5 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 13 Mar 2009 07:12:26 -0000 Author: brooks Date: Fri Mar 13 07:12:25 2009 New Revision: 189759 URL: http://svn.freebsd.org/changeset/base/189759 Log: Add support for setting the debug flags on wlan interfaces after the are created using wlandebug_ variables. Modified: head/etc/defaults/rc.conf head/etc/network.subr head/share/man/man5/rc.conf.5 Modified: head/etc/defaults/rc.conf ============================================================================== --- head/etc/defaults/rc.conf Fri Mar 13 07:09:20 2009 (r189758) +++ head/etc/defaults/rc.conf Fri Mar 13 07:12:25 2009 (r189759) @@ -197,6 +197,7 @@ ifconfig_lo0="inet 127.0.0.1" # default #ifconfig_ed0_ipx="ipx 0x00010010" # Sample IPX address family entry. #ifconfig_fxp0_name="net0" # Change interface name from fxp0 to net0. #wlans_ath0="wlan0" # wlan(4) interfaces for ath0 device +#wlandebug_wlan0="scan+auth+assoc" # Set debug flags with wlanddebug(8) #ipv4_addrs_fxp0="192.168.0.1/24 192.168.1.1-5/28" # example IPv4 address entry. # #autobridge_interfaces="bridge0" # List of bridges to check Modified: head/etc/network.subr ============================================================================== --- head/etc/network.subr Fri Mar 13 07:09:20 2009 (r189758) +++ head/etc/network.subr Fri Mar 13 07:12:25 2009 (r189759) @@ -499,7 +499,7 @@ clone_down() # childif_create() { - local cfg child child_wlans create_args ifn i + local cfg child child_wlans create_args debug_flags ifn i cfg=1 ifn=$1 @@ -509,10 +509,18 @@ childif_create() for child in ${child_wlans}; do create_args="wlandev $ifn `get_if_var $child create_args_IF`" + debug_flags="`get_if_var $child wlandebug_IF`" + if expr $child : 'wlan[0-9][0-9]*$' >/dev/null 2>&1; then ifconfig $child create ${create_args} && cfg=0 + if [ -n "${debug_flags}" ]; then + wlandebug -i $child ${debug_flags} + fi else i=`ifconfig wlan create ${create_args}` + if [ -n "${debug_flags}" ]; then + wlandebug -i $i ${debug_flags} + fi ifconfig $i name $child && cfg=0 fi if autoif $child; then Modified: head/share/man/man5/rc.conf.5 ============================================================================== --- head/share/man/man5/rc.conf.5 Fri Mar 13 07:09:20 2009 (r189758) +++ head/share/man/man5/rc.conf.5 Fri Mar 13 07:12:25 2009 (r189759) @@ -1169,6 +1169,15 @@ One or more .Xr wlan 4 devices must be created for each wireless devices as of .Fx 8.0 . +Debugging flags for +.Xr wlan 4 +devices as set by +.Xr wlandebug 8 +may be specified with an +.Va wlandebug_ Ns Aq Ar interface +variable. +The contents of this variable will be passed directly to +.Xr wlandebug 8 . .Pp If the .Va ifconfig_ Ns Aq Ar interface @@ -4065,6 +4074,7 @@ Default .Xr sysctl 8 , .Xr syslogd 8 , .Xr timed 8 , +.Xr wlandebug 8 , .Xr yp 8 , .Xr ypbind 8 , .Xr ypserv 8 ,