<commit_before># 2011-09-22	<NAME> <<EMAIL>>
#		based on vlan.sh & tuntap.sh
# Copyright (c) 2007-2008 <NAME> <<EMAIL>>
# All rights reserved. Released under the 2-clause BSD license.

_ip()
{
	if [ -x /bin/ip ]; then
		echo /bin/ip
	else
		echo /sbin/ip
	fi
}

macvlan_depend()
{
	program $(_ip)
	after interface
	before dhcp macchanger
}

_is_macvlan()
{
	[ -n "$(export RC_SVCNAME="net.${IFACE}"; service_get_value macvlan)" ]
}

_check_macvlan()
{
	if [ ! -d /sys/module/macvlan ]; then
		modprobe macvlan
		if [ ! -d /sys/module/macvlan ]; then
			eerror "MAC-VLAN support is not present in this kernel"
			return 1
		fi
	fi
}

macvlan_pre_start()
{
	# MAC-VLAN needs an existing interface to link to
	local macvlan=
	eval macvlan=\$macvlan_${IFVAR}
	[ -z "${macvlan}" ] && return 0

	_check_macvlan || return 1

	case " ${MODULES} " in
		*" ifconfig "*)
				eerror "sys-apps/iproute2 is required to configure MACVLANs"
				return 1 ;;<commit_msg>net: remove _check_macvlan function<commit_after># 2011-09-22	<NAME> <<EMAIL>>
#		based on vlan.sh & tuntap.sh
# Copyright (c) 2007-2008 <NAME> <<EMAIL>>
# All rights reserved. Released under the 2-clause BSD license.

_ip()
{
	if [ -x /bin/ip ]; then
		echo /bin/ip
	else
		echo /sbin/ip
	fi
}

macvlan_depend()
{
	program $(_ip)
	after interface
	before dhcp macchanger
}

_is_macvlan()
{
	[ -n "$(export RC_SVCNAME="net.${IFACE}"; service_get_value macvlan)" ]
}

macvlan_pre_start()
{
	# MAC-VLAN needs an existing interface to link to
	local macvlan=
	eval macvlan=\$macvlan_${IFVAR}
	[ -z "${macvlan}" ] && return 0

	case " ${MODULES} " in
		*" ifconfig "*)
				eerror "sys-apps/iproute2 is required to configure MACVLANs"
				return 1 ;;
{'fraction_non_alphanumeric': 0.1437831467295227, 'fraction_numerical': 0.024749558043606363, 'mean_word_length': 3.5401069518716577, 'pattern_counts': {'":': 0, '<': 15, '<?xml version=': 0, '>': 15, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2170911', 'n_tokens_mistral': 756, 'n_tokens_neox': 689, 'n_words': 184}