dmake: do not set MAKEFLAGS=k
[unleashed/tickless.git] / usr / src / cmd / fm / modules / common / event-transport / etm_proto.h
blob128aa16cced27f87995226b970c4193a30813804
1 /*
2 * CDDL HEADER START
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]
19 * CDDL HEADER END
23 * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
24 * Use is subject to license terms.
28 * FMA ETM-to-ETM Protocol header
30 * const/type defns for protocol used between two event transport
31 * modules (ETMs)
34 #ifndef _ETM_PROTO_H
35 #define _ETM_PROTO_H
37 #pragma ident "%Z%%M% %I% %E% SMI"
39 #ifdef __cplusplus
40 extern "C" {
41 #endif
43 #include <sys/types.h>
45 #define ETM_DELIM "\177ETM" /* Start of header delimiter */
46 #define ETM_DELIMLEN 4 /* Length of header deimiter */
48 typedef struct etm_proto_header {
49 char hdr_delim[ETM_DELIMLEN]; /* Start of header delimiter */
50 uint8_t hdr_ver; /* ETM protocol version */
51 uint8_t hdr_type; /* Header type */
52 uint8_t hdr_pad1; /* reserved/padding/alignment */
53 uint8_t hdr_pad2; /* reserved/padding/alignment */
54 uint32_t hdr_msglen; /* Length of following message */
55 } etm_proto_hdr_t;
57 typedef enum etm_proto_header_type {
58 ETM_HDR_TYPE_TOO_LOW = 0, /* Range check place holder */
59 ETM_HDR_MSG, /* FMA event to follow */
60 ETM_HDR_S_RESTART, /* Server re-start indication */
61 ETM_HDR_C_HELLO, /* Client startup indication */
62 ETM_HDR_S_HELLO, /* Server response to C_HELLO */
63 ETM_HDR_ACK, /* Acknowledgement */
64 ETM_HDR_NAK, /* Negative acknowledgement */
65 ETM_HDR_SHUTDOWN, /* Notify remote ETM of shutdown */
66 ETM_HDR_TYPE_TOO_HIGH /* Range check place holder */
67 } etm_proto_hdr_type_t;
69 #define ETM_HDRLEN sizeof (etm_proto_hdr_t)
70 #define ETM_PROTO_V1 1
72 #ifdef __cplusplus
74 #endif
76 #endif /* _ETM_PROTO_H */