View | Details | Raw Unified | Return to bug 208854
Collapse All | Expand All

(-)scripts/functions.original (+37 lines)
Lines 80-85 Link Here
80
	echo ${octet[1]}.${octet[2]}.${octet[3]}.${octet[4]}
80
	echo ${octet[1]}.${octet[2]}.${octet[3]}.${octet[4]}
81
}
81
}
82
82
83
# this checks whether we have an isa network card the module of which should be loaded!
84
check_isacards() {
85
	for i in ifcfg*; do
86
		# find out whether we have an isa-type network card ...
87
		ISACARD=`awk -F = '{\
88
			if(match($0, "_nm_name")){\
89
				if(match($2, "isa")){\
90
					gsub(/\047/, "", $2);\
91
					printf("hwcfg-%s", $2)\
92
					}\
93
				}\
94
			}' $i`
95
		# ok. ISACARD contains the name of a hardware-entry now.
96
		# find out the name of the corresponding module!
97
		# comment: to replace "'" in awk, I use octal writing \047.
98
		# let me know if you have a better idea!
99
		if [ "" != "${ISACARD}" ]; then
100
			ISAMODULE=`awk -F = '{\
101
				if(match($1, "MODULE")){\
102
					gsub(/\047/, "", $2);\
103
					printf("%s", $2)\
104
					}\
105
				}' ../hardware/${ISACARD}`
106
			if [ "" != "${ISAMODULE}" ]; then
107
				LOADED=`lsmod | grep ${ISAMODULE}`
108
			else
109
				LOADED="NO_MODULE_TO_LOAD"
110
			fi
111
			if [ "" = "${LOADED}" ]; then
112
				echo -n "Loading ${ISAMODULE} - module (Network) "
113
					modprobe ${ISAMODULE} > /dev/null 2>&1
114
				echo "$rc_done"
115
			fi
116
		fi
117
	done
118
}
119
83
is_iface_available () {
120
is_iface_available () {
84
	test -z "$1" && return 1
121
	test -z "$1" && return 1
85
	case $1 in
122
	case $1 in
(-)scripts/network.original (+1 lines)
Lines 630-635 Link Here
630
630
631
case "$ACTION" in
631
case "$ACTION" in
632
	start)
632
	start)
633
		check_isacards
633
		echo Setting up network interfaces:
634
		echo Setting up network interfaces:
634
		/sbin/ifstatus $LO &>/dev/null && unset $LO;
635
		/sbin/ifstatus $LO &>/dev/null && unset $LO;
635
		for IFACE in ${INTERFACE:- $LO
636
		for IFACE in ${INTERFACE:- $LO

Return to bug 208854