Author: hrs Date: Sat Oct 11 20:28:04 2014 New Revision: 272959 URL: https://svnweb.freebsd.org/changeset/base/272959
Log: Rename s/network/netif/ and set netif_enable for namespace consistency. Modified: head/etc/defaults/rc.conf head/etc/rc.d/netif Modified: head/etc/defaults/rc.conf ============================================================================== --- head/etc/defaults/rc.conf Sat Oct 11 20:25:19 2014 (r272958) +++ head/etc/defaults/rc.conf Sat Oct 11 20:28:04 2014 (r272959) @@ -110,6 +110,7 @@ synchronous_dhclient="NO" # Start dhclie # interfaces during startup. defaultroute_delay="30" # Time to wait for a default route on a DHCP interface. defaultroute_carrier_delay="5" # Time to wait for carrier while waiting for a default route. +netif_enable="YES" # Set to YES to initialize network interfaces netif_ipexpand_max="2048" # Maximum number of IP addrs in a range spec. wpa_supplicant_program="/usr/sbin/wpa_supplicant" wpa_supplicant_flags="-s" # Extra flags to pass to wpa_supplicant Modified: head/etc/rc.d/netif ============================================================================== --- head/etc/rc.d/netif Sat Oct 11 20:25:19 2014 (r272958) +++ head/etc/rc.d/netif Sat Oct 11 20:28:04 2014 (r272959) @@ -33,9 +33,10 @@ . /etc/rc.subr . /etc/network.subr -name="network" -start_cmd="network_start" -stop_cmd="network_stop" +name="netif" +rcvar="${name}_enable" +start_cmd="netif_start" +stop_cmd="netif_stop" cloneup_cmd="clone_up" clonedown_cmd="clone_down" clear_cmd="doclear" @@ -47,7 +48,7 @@ cmdifn= set_rcvar_obsolete ipv6_enable ipv6_activate_all_interfaces set_rcvar_obsolete ipv6_prefer -network_start() +netif_start() { local _if @@ -71,7 +72,7 @@ network_start() ifnet_rename $cmdifn # Configure the interface(s). - network_common ifn_start $cmdifn + netif_common ifn_start $cmdifn if [ -f /etc/rc.d/ipfilter ] ; then # Resync ipfilter @@ -87,19 +88,19 @@ network_start() fi } -network_stop() +netif_stop() { _clone_down=1 - network_stop0 $* + netif_stop0 $* } doclear() { _clone_down= - network_stop0 $* + netif_stop0 $* } -network_stop0() +netif_stop0() { local _if @@ -108,7 +109,7 @@ network_stop0() cmdifn=$* # Deconfigure the interface(s) - network_common ifn_stop $cmdifn + netif_common ifn_stop $cmdifn # Destroy cloned interfaces if [ -n "$_clone_down" ]; then @@ -126,28 +127,28 @@ vnet_up() { cmdifn=$* - network_common ifn_vnetup $cmdifn + netif_common ifn_vnetup $cmdifn } vnet_down() { cmdifn=$* - network_common ifn_vnetdown $cmdifn + netif_common ifn_vnetdown $cmdifn } -# network_common routine +# netif_common routine # Common configuration subroutine for network interfaces. This # routine takes all the preparatory steps needed for configuriing # an interface and then calls $routine. -network_common() +netif_common() { local _cooked_list _tmp_list _fail _func _ok _str _cmdifn _func= if [ -z "$1" ]; then - err 1 "network_common(): No function name specified." + err 1 "netif_common(): No function name specified." else _func="$1" shift _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"