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]
23 * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
24 * Use is subject to license terms.
28 * etm_impl.h FMA ETM and Transport shared implementation header
31 * const/type defns shared between the event transport module (ETM)
32 * and the ETM-to-Transport API
43 * ------------------------------ includes -----------------------------------
46 #include <sys/fm/protocol.h>
47 #include <fm/fmd_api.h>
49 #include "etm_xport_api.h"
52 * ------------------------------- macros ------------------------------------
55 /* define common macros here vs #include to ease Solaris-Linux portability */
58 #define MIN(x, y) ((x) < (y) ? (x) : (y))
61 #define MAX(x, y) ((x) > (y) ? (x) : (y))
64 #define ABS(x) ((x) < (0) ? (-(x)) : (x))
67 /* ETM I/O operations: read, write, peek */
69 #define ETM_IO_OP_RD (1)
70 #define ETM_IO_OP_WR (2)
71 #define ETM_IO_OP_PK (3)
75 #define ETM_SLEEP_VERY_QUIK (0)
76 #define ETM_SLEEP_QUIK (1)
77 #define ETM_SLEEP_SLOW (16)
78 #define ETM_SLEEP_VERY_SLOW (16 * 16)
81 * ----------------------------- property names ------------------------------
84 #define ETM_PROP_NM_XPORT_ADDRS "etm_xport_addrs"
86 #define ETM_PROP_NM_DEBUG_LVL "etm_debug_lvl"
87 #define ETM_PROP_NM_DEBUG_MAX_EV_CNT "etm_debug_max_ev_cnt"
89 #define ETM_PROP_NM_CONSOLE "etm_alert_console"
90 #define ETM_PROP_NM_SYSLOGD "etm_alert_syslog"
91 #define ETM_PROP_NM_FACILITY "etm_alert_facility"
93 #define ETM_PROP_NM_MAX_RESP_Q_LEN "etm_resp_q_max_len"
94 #define ETM_PROP_NM_FMA_RESP_WAIT_TIME "etm_fma_resp_wait_time"
96 #define ETM_PROP_NM_BAD_ACC_TO_SEC "etm_bad_acc_to_sec"
99 * --------------------------------- prolog ----------------------------------
106 #endif /* _ETM_IMPL_H */