postinstall revision 2a8164df8a5f42c8a00f10c67d7bc84f80ae9c41
3832N/A#!/bin/sh
3832N/A#
3832N/A# CDDL HEADER START
3832N/A#
3832N/A# The contents of this file are subject to the terms of the
3832N/A# Common Development and Distribution License (the "License").
3832N/A# You may not use this file except in compliance with the License.
3832N/A#
3832N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
3832N/A# or http://www.opensolaris.org/os/licensing.
3832N/A# See the License for the specific language governing permissions
3832N/A# and limitations under the License.
3832N/A#
3832N/A# When distributing Covered Code, include this CDDL HEADER in each
3832N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
3832N/A# If applicable, add the following below this CDDL HEADER, with the
3832N/A# fields enclosed by brackets "[]" replaced with your own identifying
3832N/A# information: Portions Copyright [yyyy] [name of copyright owner]
3832N/A#
3832N/A# CDDL HEADER END
3832N/A#
3832N/A#
3832N/A# Copyright 2009 Sun Microsystems, Inc. All rights reserved.
3832N/A# Use is subject to license terms.
4458N/A#
6033N/A#
3832N/A
3832N/APATH=/usr/bin:/usr/sbin:$PATH; export PATH
3832N/A
3832N/A# Driver definitions
3832N/ADRVR_NAME=fcoe
3832N/ADRVR_PERM="-m '* 0600 root sys'"
3832N/ADRVR_CLASS=""
3832N/ADRVR_ALIASES=""
3832N/A
3832N/A
3832N/Aif [ -z "${BASEDIR}" ]; then
4714N/A echo "\n$0 Failed: BASEDIR is not set.\n" >&2
3832N/A exit 1
3832N/Afi
3832N/A
3832N/A# Remove existing definition, if it exists.
3832N/A/usr/sbin/rem_drv -b "${BASEDIR}" ${DRVR_NAME} > /dev/null 2>&1
3832N/A
4714N/AADD_DRV="add_drv -n -b ${BASEDIR}"
4714N/A
4714N/Aeval ${ADD_DRV} "${DRVR_PERM}" ${DRVR_CLASS} "${DRVR_ALIASES}" ${DRVR_NAME}
4714N/Aif [ $? -ne 0 ]; then
4714N/A echo "\nCommand Failed:\n${ADD_DRV} "${DRVR_PERM}" ${DRVR_CLASS} \
4714N/A "${DRVR_ALIASES}" ${DRVR_NAME}\n" >&2
4714N/A exit 1
4714N/Afi
4714N/A
4714N/Aexit 0
4714N/A