dmake: do not set MAKEFLAGS=k
[unleashed/tickless.git] / usr / src / cmd / cmd-inet / usr.sbin / snoop / fw.h
blob32746237c33448d4e1829249ef8955e4b4681c57
1 /*
2 * CDDL HEADER START
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License, Version 1.0 only
6 * (the "License"). You may not use this file except in compliance
7 * with the License.
9 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 * or http://www.opensolaris.org/os/licensing.
11 * See the License for the specific language governing permissions
12 * and limitations under the License.
14 * When distributing Covered Code, include this CDDL HEADER in each
15 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 * If applicable, add the following below this CDDL HEADER, with the
17 * fields enclosed by brackets "[]" replaced with your own identifying
18 * information: Portions Copyright [yyyy] [name of copyright owner]
20 * CDDL HEADER END
23 * Copyright (c) 1993 by Sun Microsystems, Inc.
26 #ifndef _FW_H
27 #define _FW_H
29 #pragma ident "%Z%%M% %I% %E% SMI"
31 #include <rpc/rpc.h>
32 #include "fakewin.h"
34 #ifdef __cplusplus
35 extern "C" {
36 #endif
39 * Header file for the framework.
41 #define CTXTLEN 1024
43 struct Op_arg_item {
44 char _TKFAR *name;
45 char _TKFAR *value;
46 struct Op_arg_item _TKFAR *next;
48 typedef struct Op_arg_item Op_arg_item;
50 struct Op_row_link {
51 Op_arg_item _TKFAR *first;
52 Op_arg_item _TKFAR *last;
53 struct Op_row_link _TKFAR *next;
55 typedef struct Op_row_link Op_row_link;
57 struct Op_arg {
58 Op_row_link _TKFAR *first;
59 Op_row_link _TKFAR *last;
60 Op_row_link _TKFAR *curr;
61 Op_arg_item _TKFAR *cura;
62 u_long rows;
63 bool_t xdr_flag;
65 typedef struct Op_arg Op_arg;
67 enum Fw_err {
68 FW_ERR_NONE = 0,
69 FW_ERR_FW = 1,
70 FW_ERR_OP = 2
72 typedef enum Fw_err Fw_err;
74 struct Op_err {
75 Fw_err type;
76 u_long code;
77 bool_t xdr_flag;
78 char _TKFAR *message;
80 typedef struct Op_err Op_err;
82 typedef char invk_context[CTXTLEN];
84 struct invk_result {
85 Op_err _TKFAR *err;
86 Op_arg _TKFAR *arg;
87 bool_t eof;
89 typedef struct invk_result invk_result;
91 struct invk_request {
92 char _TKFAR *category;
93 char _TKFAR *op;
94 char _TKFAR *vers;
95 char _TKFAR *locale;
96 u_long threshold;
97 invk_context context;
98 Op_arg _TKFAR *arg;
100 typedef struct invk_request invk_request;
102 struct more_request {
103 invk_context context;
104 u_long threshold;
106 typedef struct more_request more_request;
108 struct kill_request {
109 invk_context context;
111 typedef struct kill_request kill_request;
113 #define FW_KV_DELIM "="
114 #define FW_KV_DELIM_CH '='
115 #define FW_VK_DELIM "\n"
116 #define FW_VK_DELIM_CH '\n';
117 #define FW_INPUT_VERS_VAL 1
118 #define FW_INPUT_VERS_STR "1"
119 #define FW_OUTPUT_VERS_VAL 1
120 #define FW_OUTPUT_VERS_STR "1"
121 #define FW_INPUT_VERS_KEY "_SUNW_AO_INPUT_VERS"
122 #define FW_OUTPUT_VERS_KEY "_SUNW_AO_OUTPUT_VERS"
123 #define FW_ROW_MARKER_KEY "_SUNW_AO_BEGIN_ROW"
124 #define FW_ROW_MARKER FW_ROW_MARKER_KEY FW_KV_DELIM FW_OUTPUT_VERS_STR \
125 FW_VK_DELIM
126 #define FW_INPUT_VERS FW_INPUT_VERS_KEY FW_KV_DELIM FW_INPUT_VERS_STR \
127 FW_VK_DELIM
128 #define FW_OUTPUT_VERS FW_OUTPUT_VERS_KEY FW_KV_DELIM FW_OUTPUT_VERS_STR \
129 FW_VK_DELIM
130 #define FW_ERR_MSG_MAX 2047
131 #define FW_UNIX_USER "UU"
133 #define FW_SUCCESS 0
134 #define FW_ERROR -1
135 #define FW_TIMEOUT -2
137 #define SN_LOCALE_PATH_VAR "_SN_LOCALE_PATH"
138 #define SN_UNAME_VAR "_SN_UNAME"
139 #define SN_UID_VAR "_SN_UID"
141 #include "fw_lib.h"
143 #ifdef __cplusplus
145 #endif
147 #endif /* !_FW_H */