From: David van Moolenbroek Date: Mon, 1 Dec 2014 17:35:21 +0000 (+0000) Subject: etc/usr/rc: fix argument passing for net drivers X-Git-Url: http://zhaoyanbai.com/repos/%22http:/www.isc.org/icons/zpipe.c?a=commitdiff_plain;h=cb796b755139385df69f1f6762784b3edbaa7651;p=minix.git etc/usr/rc: fix argument passing for net drivers The expected argument name would include the instance number, which is not only redundant in many cases (FOOETHn_n=arg.., "n" being the instance number) and conflicted with what netconf(8) does, but some drivers need to be able to see the arguments for all instances of its driver type--for example, dp8390 needs to know how many earlier instances have been configured to use PCI. Change-Id: I4830b823352722f554a032979464aba8b08fc166 --- diff --git a/etc/usr/rc b/etc/usr/rc index f540bdf97..16d8b1a8e 100644 --- a/etc/usr/rc +++ b/etc/usr/rc @@ -184,7 +184,7 @@ start|autoboot) for label in $(get_eth_labels); do driver=$(echo $label | sed 's/\(.*\)_.*/\1/') instance=$(echo $label | sed 's/.*_//') - eval arg=\$${label}_arg + eval arg=\$${driver}_arg if [ ! -z "$arg" ]; then arg=" $arg"; fi arg="-args \"instance=$instance$arg\"" eval up $driver -label $label $arg -period 5HZ