4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
22 * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
23 * Use is subject to license terms.
29 #pragma ident "%Z%%M% %I% %E% SMI"
36 #define TSALARM_ENABLE 1
37 #define TSALARM_DISABLE 2
38 #define TSALARM_STATUS 3
41 #define TSALARM_CRITICAL 0
42 #define TSALARM_MAJOR 1
43 #define TSALARM_MINOR 2
44 #define TSALARM_USER 3
47 #define TSALARM_STATE_ON 1
48 #define TSALARM_STATE_OFF 2
49 #define TSALARM_STATE_UNKNOWN 3
53 #define TSALARM_ERROR 2
56 #define TSALARM_SUCCESS 0
57 #define TSALARM_CHANNEL_INIT_FAILURE -1
58 #define TSALARM_NULL_REQ_DATA -2
59 #define TSALARM_COMM_FAILURE -3
60 #define TSALARM_UNBOUND_PACKET_RECVD -4
61 #define TSALARM_GET_ERROR -5
62 #define TSALARM_SET_ERROR -6
65 * alarm set/get request message
67 typedef struct tsalarm_req
{
69 uint32_t alarm_action
;
73 * alarm set/get response message
75 typedef struct tsalarm_resp
{
81 int tsalarm_get(uint32_t alarm_type
, uint32_t *alarm_state
);
82 int tsalarm_set(uint32_t alarm_type
, uint32_t alarm_state
);
88 #endif /* _TSALARM_H */