xref: /illumos-gate/usr/src/cmd/oplhpd/svc-oplhpd (revision a1e4d62bc1ea0bd683c63f185da43cda7aec8f20)
1*a4ac8bb3Sdnielsen#!/bin/sh
2*a4ac8bb3Sdnielsen#
3*a4ac8bb3Sdnielsen# CDDL HEADER START
4*a4ac8bb3Sdnielsen#
5*a4ac8bb3Sdnielsen# The contents of this file are subject to the terms of the
6*a4ac8bb3Sdnielsen# Common Development and Distribution License (the "License").
7*a4ac8bb3Sdnielsen# You may not use this file except in compliance with the License.
8*a4ac8bb3Sdnielsen#
9*a4ac8bb3Sdnielsen# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10*a4ac8bb3Sdnielsen# or http://www.opensolaris.org/os/licensing.
11*a4ac8bb3Sdnielsen# See the License for the specific language governing permissions
12*a4ac8bb3Sdnielsen# and limitations under the License.
13*a4ac8bb3Sdnielsen#
14*a4ac8bb3Sdnielsen# When distributing Covered Code, include this CDDL HEADER in each
15*a4ac8bb3Sdnielsen# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16*a4ac8bb3Sdnielsen# If applicable, add the following below this CDDL HEADER, with the
17*a4ac8bb3Sdnielsen# fields enclosed by brackets "[]" replaced with your own identifying
18*a4ac8bb3Sdnielsen# information: Portions Copyright [yyyy] [name of copyright owner]
19*a4ac8bb3Sdnielsen#
20*a4ac8bb3Sdnielsen# CDDL HEADER END
21*a4ac8bb3Sdnielsen#
22*a4ac8bb3Sdnielsen# Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
23*a4ac8bb3Sdnielsen# Use is subject to license terms.
24*a4ac8bb3Sdnielsen#
25*a4ac8bb3Sdnielsen#ident	"%Z%%M%	%I%	%E% SMI"
26*a4ac8bb3Sdnielsen
27*a4ac8bb3Sdnielsen. /lib/svc/share/smf_include.sh
28*a4ac8bb3Sdnielsen
29*a4ac8bb3Sdnielsensparc_enterprise="SUNW,SPARC-Enterprise"
30*a4ac8bb3SdnielsenOPLHPD=/usr/platform/${sparc_enterprise}/lib/sparcv9/oplhpd
31*a4ac8bb3Sdnielsenplatform=`/sbin/uname -i`
32*a4ac8bb3Sdnielsen
33*a4ac8bb3Sdnielsenif [ $platform = "$sparc_enterprise" ]; then
34*a4ac8bb3Sdnielsen	$OPLHPD				# Fail if can't execute
35*a4ac8bb3Sdnielsen	exit				# Use oplhpd's exit status
36*a4ac8bb3Sdnielsenelse
37*a4ac8bb3Sdnielsen	echo "$SMF_FMRI is not supported on this platform."
38*a4ac8bb3Sdnielsen	exit $SMF_EXIT_ERR_CONFIG
39*a4ac8bb3Sdnielsenfi
40*a4ac8bb3Sdnielsen
41*a4ac8bb3Sdnielsenexit 0
42