# function to produce the info for the System file for the RTL
# boards
#
system_r7e() {
bd=$1
IRQ=0;
DMA=-1;
FORCE="auto";
BIO=0;
EIO=0;
BUS=0;
DMACHAN=-1
NMINORS="1"
############################################
##########clt 11/15/1996####################
####change space.c file ####################
#set -x
#prompt_select "Enter auto, force 100 or 10bps:" $FORCE "auto 10 100" || cleanup $FAIL
#FORCE=$result
#[ "$result" = "auto" ] && FORCE="0"
#[ "$result" = "10" ] && FORCE="10"
#[ "$result" = "100" ] && FORCE="100"
prompt_select "Enter hardware_default_setting, or auto, force 10 or 10bps, half or full duplex:" $FORCE "hwset auto 10half 10full 100half 100full" || cleanup $FAIL
FORCE=$result
[ "$result" = "hwset" ] && FORCE="0"
[ "$result" = "auto" ] && FORCE="2"
[ "$result" = "10half" ] && FORCE="10"
[ "$result" = "10full" ] && FORCE="11"
[ "$result" = "100half" ] && FORCE="100"
[ "$result" = "100full" ] && FORCE="101"
spacef=${CONF}/pack.d/${drv}0/space.c
a=`grep "^#define[ ]${drv}force_$bd" $spacef`
c="#define ${drv}force_$bd $FORCE"
sed "s/${a}/${c}/" $spacef > /tmp/bog$$
cp /tmp/bog$$ $spacef
rm /tmp/bog$$
echo "Detect PCI fast ethernet adapter hardware automatically."
}
# main()
#
#
# get the name of the init script being run, since one script
# is used for multiple drivers; get the number at the end of the
# script's name
#
if [ $# -gt 1 ]
then
name_below=$1; if_below=$2
name_above=$3; if_above=$4
configure=$5
fi
base=`basename $0`
drv=`echo $base | sed -e 's/[0-9]*$//`
bd=`expr $base : '.*\(.\)'`
makedevs $OK
check_args $drv $bd
#
# verify the driver is in the kernel link-kit
#
idcheck -p $base -i /tmp/dev$$
if [ $? -le 16 ]
then
echo "Error: $base driver is not installed"
cleanup $FAIL
fi
echo "Reconfiguring the $drv driver"
cd /usr/lib/lli/$drv
makedevs
#
# create the temporary directory for installing the driver
#
cd /tmp; rm -rf $base
mkdir $base; cd $base
DMACHAN="-1"
#
# set rel, type variables.
#
os_type
# get the interrupt vector & Base I/O address for the board that we are removing