#!/bin/sh

basedir="/"
drvname=rtls

set -x

# install driver
cp rtls ${basedir}/kernel/drv/${drvname}
chmod 755 ${basedir}/kernel/drv/${drvname}
chown root:sys ${basedir}/kernel/drv/${drvname}

# update
#    /etc/driver_aliases
#    /etc/name_to_major
#
grep "^${drvname}\>" /etc/name_to_major >  /dev/null 2>&1 \
  &&  rem_drv -b ${basedir} ${drvname}
#add_drv -v -b ${basedir} -i '"pci1186,1301" "pci10ec,8139"' ${drvname}
add_drv -v -i '"pci1186,1301" "pci10ec,8139" "pci1113,1211"' ${drvname}

exit 0
