#!/sbin/sh
#------------------------------------------------------------------#
#
# HPUX_ID: @(#) $Revision: 15.2 $ generated on Mon Aug 21 22:16:21 EDT 2000
#
# (c)Copyright 1983-2000 Hewlett-Packard Co.,  All Rights Reserved.
#
#------------------------------------------------------------------#
# SD postinstall script template for 11.X patches.                 #
#------------------------------------------------------------------#
# This file is optional for all 11.X patches.  The purpose of this #
# script is to prepare for a kernel build when required by the     #
# install conditions.  The script can also drive events that must  #
# occur before a system reboot occurs.                             #
#------------------------------------------------------------------#

_PATCHID=PHNE_22244

UTILS="/usr/lbin/sw/control_utils"

if [ ! -f $UTILS ]; then
    echo "ERROR:   Cannot find $UTILS"
    exit 1
fi

. $UTILS
exitval=$SUCCESS

#####
##### Insert any code you may require at this point in the script.
##### Pay attention to the exitval variable and set appropriately
##### in your code.  If you are unsure as to what types of operations
##### are legal in this file and what types aren't, consult the 
##### "Guidelines for SD Control Scripts" document.
#####
##### START_CUSTOMIZATION_HERE

####### add the drivers to the kernel
RES0=0

mod_systemfile $SW_SYSTEM_FILE_PATH -a btlan3
RES0=$?


####### see if the mod_systemfiles worked
if [ $RES0 -ne 0 ] ; then
        echo "ERROR:   Cannot modify the kernel configuration file.  The"
        echo "         appropriate 100BT LAN driver must be manually configured"
        echo "         into the kernel."
        exitval=$FAILURE
fi


####### add the LLA/MAC pseudo driver to the kernel
RES0=0

mod_systemfile $SW_SYSTEM_FILE_PATH -a maclan
RES0=$?


####### see if the mod_systemfiles worked
if [ $RES0 -ne 0 ] ; then
        echo "ERROR:   Cannot modify the kernel configuration file.  The"
        echo "         LLA/MAC pseudo driver must be manually configured"
        echo "         into the kernel."
        exit $FAILURE
fi

exit $exitval
