#############################################
# SMI CM-II Daughter card driver
#
# SMI Daughter card allows for 3 serial
# ports, 2 Leds, and one push-button pin
# connected to the TS7400 Dio pins.
#
#############################################
insmod /etc/init.d/tsSmiCmDio.o >/tmp/smiCmDio.out 2>&1

if test "$?" -eq 0; then
	cat /tmp/smiCmDio.out
fi

##############################################
# increase the max number of open files
##############################################
echo "65536" > /proc/sys/fs/file-max

##############################################
# cleanup /etc/mtab
##############################################
rm /etc/mtab
echo "proc /proc proc rw 0 0 " > /etc/mtab
echo "/dev/mtdblock/3 / yaffs2 rw 0 0 " >> /etc/mtab


##############################################
# start up CM-II daemon 
##############################################
if  test -f /smi/bin/daemon/ts7400/cmMain ; then
   echo "starting cm-II daemon..."
   /smi/bin/daemon/ts7400/cmMain
   echo "cmMain started.." > /tmp/cmMainStart.out 
else
   echo "cm-II daemon not found..."
   echo "/smi/bin/daemon/ts7400/cmMain not found..." > /tmp/cmMainStart.out
fi

          

