1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 /******************************************************************************
4 * (C)Copyright 1998,1999 SysKonnect,
5 * a business unit of Schneider & Koch & Co. Datensysteme GmbH.
7 * The information in this file is provided "AS IS" without warranty.
9 ******************************************************************************/
19 typedef u_long Counter
;
20 typedef u_char TimeStamp
[8] ;
21 typedef struct fddi_addr LongAddr
;
22 typedef u_long Timer_2
;
23 typedef u_long Timer
;
24 typedef u_short ResId
;
25 typedef u_short SMTEnum
;
26 typedef u_char SMTFlag
;
34 * bits for bit string "available_path"
36 #define MIB_PATH_P (1<<0)
37 #define MIB_PATH_S (1<<1)
38 #define MIB_PATH_L (1<<2)
41 * bits for bit string PermittedPaths & RequestedPaths (SIZE(8))
43 #define MIB_P_PATH_LOCAL (1<<0)
44 #define MIB_P_PATH_SEC_ALTER (1<<1)
45 #define MIB_P_PATH_PRIM_ALTER (1<<2)
46 #define MIB_P_PATH_CON_ALTER (1<<3)
47 #define MIB_P_PATH_SEC_PREFER (1<<4)
48 #define MIB_P_PATH_PRIM_PREFER (1<<5)
49 #define MIB_P_PATH_CON_PREFER (1<<6)
50 #define MIB_P_PATH_THRU (1<<7)
55 #define MIB_PATH_ISOLATED 0
56 #define MIB_PATH_LOCAL 1
57 #define MIB_PATH_SECONDARY 2
58 #define MIB_PATH_PRIMARY 3
59 #define MIB_PATH_CONCATENATED 4
60 #define MIB_PATH_THRU 5
65 #define MIB_PMDCLASS_MULTI 0
66 #define MIB_PMDCLASS_SINGLE1 1
67 #define MIB_PMDCLASS_SINGLE2 2
68 #define MIB_PMDCLASS_SONET 3
69 #define MIB_PMDCLASS_LCF 4
70 #define MIB_PMDCLASS_TP 5
71 #define MIB_PMDCLASS_UNKNOWN 6
72 #define MIB_PMDCLASS_UNSPEC 7
75 * enum SMTStationStatus
77 #define MIB_SMT_STASTA_CON 0
78 #define MIB_SMT_STASTA_SEPA 1
79 #define MIB_SMT_STASTA_THRU 2
86 u_char fddiPRPMFPasswd
[8] ;
87 struct smt_sid fddiPRPMFStation
;
91 * private variables for static allocation of the
94 u_long fddiESSPayload
; /* payload for static alloc */
95 u_long fddiESSOverhead
; /* frame ov for static alloc */
96 u_long fddiESSMaxTNeg
; /* maximum of T-NEG */
97 u_long fddiESSMinSegmentSize
; /* min size of the sync frames */
98 u_long fddiESSCategory
; /* category for the Alloc req */
99 short fddiESSSynchTxMode
; /* send all LLC frames as sync */
103 * private variables for the Synchronous Bandwidth Allocator
105 char fddiSBACommand
; /* holds the parsed SBA cmd */
106 u_char fddiSBAAvailable
; /* SBA allocatable value */
112 struct smt_sid fddiSMTStationId
;
113 u_short fddiSMTOpVersionId
;
114 u_short fddiSMTHiVersionId
;
115 u_short fddiSMTLoVersionId
;
116 u_char fddiSMTManufacturerData
[32] ;
117 u_char fddiSMTUserData
[32] ;
118 u_short fddiSMTMIBVersionId
;
123 u_char fddiSMTMac_Ct
;
124 u_char fddiSMTNonMaster_Ct
;
125 u_char fddiSMTMaster_Ct
;
126 u_char fddiSMTAvailablePaths
;
127 u_short fddiSMTConfigCapabilities
;
128 u_short fddiSMTConfigPolicy
;
129 u_short fddiSMTConnectionPolicy
;
130 u_short fddiSMTTT_Notify
;
131 u_char fddiSMTStatRptPolicy
;
132 u_long fddiSMTTrace_MaxExpiration
;
133 u_short fddiSMTPORTIndexes
[NUMPHYS
] ;
134 u_short fddiSMTMACIndexes
;
135 u_char fddiSMTBypassPresent
;
140 SMTEnum fddiSMTECMState
;
141 SMTEnum fddiSMTCF_State
;
142 SMTEnum fddiSMTStationStatus
;
143 u_char fddiSMTRemoteDisconnectFlag
;
144 u_char fddiSMTPeerWrapFlag
;
149 TimeStamp fddiSMTTimeStamp
;
150 TimeStamp fddiSMTTransitionTimeStamp
;
151 SetCountType fddiSMTSetCount
;
152 struct smt_sid fddiSMTLastSetStationId
;
155 u_short fddiMACFrameStatusFunctions
;
156 Timer_2 fddiMACT_MaxCapabilitiy
;
157 Timer_2 fddiMACTVXCapabilitiy
;
160 u_char fddiMACMultiple_N
; /* private */
161 u_char fddiMACMultiple_P
; /* private */
162 u_char fddiMACDuplicateAddressCond
;/* private */
163 u_char fddiMACAvailablePaths
;
164 u_short fddiMACCurrentPath
;
165 LongAddr fddiMACUpstreamNbr
;
166 LongAddr fddiMACDownstreamNbr
;
167 LongAddr fddiMACOldUpstreamNbr
;
168 LongAddr fddiMACOldDownstreamNbr
;
169 SMTEnum fddiMACDupAddressTest
;
170 u_short fddiMACRequestedPaths
;
171 SMTEnum fddiMACDownstreamPORTType
;
175 LongAddr fddiMACSMTAddress
;
178 Timer_2 fddiMACT_Min
; /* private */
179 Timer_2 fddiMACT_ReqMIB
;
180 Timer_2 fddiMACT_Req
; /* private */
181 Timer_2 fddiMACT_Neg
;
182 Timer_2 fddiMACT_MaxMIB
;
183 Timer_2 fddiMACT_Max
; /* private */
184 Timer_2 fddiMACTvxValueMIB
;
185 Timer_2 fddiMACTvxValue
; /* private */
186 Timer_2 fddiMACT_Pri0
;
187 Timer_2 fddiMACT_Pri1
;
188 Timer_2 fddiMACT_Pri2
;
189 Timer_2 fddiMACT_Pri3
;
190 Timer_2 fddiMACT_Pri4
;
191 Timer_2 fddiMACT_Pri5
;
192 Timer_2 fddiMACT_Pri6
;
195 Counter fddiMACFrame_Ct
;
196 Counter fddiMACCopied_Ct
;
197 Counter fddiMACTransmit_Ct
;
198 Counter fddiMACToken_Ct
;
199 Counter fddiMACError_Ct
;
200 Counter fddiMACLost_Ct
;
201 Counter fddiMACTvxExpired_Ct
;
202 Counter fddiMACNotCopied_Ct
;
203 Counter fddiMACRingOp_Ct
;
205 Counter fddiMACSMTCopied_Ct
; /* private */
206 Counter fddiMACSMTTransmit_Ct
; /* private */
208 /* private for delta ratio */
209 Counter fddiMACOld_Frame_Ct
;
210 Counter fddiMACOld_Copied_Ct
;
211 Counter fddiMACOld_Error_Ct
;
212 Counter fddiMACOld_Lost_Ct
;
213 Counter fddiMACOld_NotCopied_Ct
;
215 /* FrameErrorConditionGrp */
216 u_short fddiMACFrameErrorThreshold
;
217 u_short fddiMACFrameErrorRatio
;
219 /* NotCopiedConditionGrp */
220 u_short fddiMACNotCopiedThreshold
;
221 u_short fddiMACNotCopiedRatio
;
224 SMTEnum fddiMACRMTState
;
225 SMTFlag fddiMACDA_Flag
;
226 SMTFlag fddiMACUNDA_Flag
;
227 SMTFlag fddiMACFrameErrorFlag
;
228 SMTFlag fddiMACNotCopiedFlag
;
229 SMTFlag fddiMACMA_UnitdataAvailable
;
230 SMTFlag fddiMACHardwarePresent
;
231 SMTFlag fddiMACMA_UnitdataEnable
;
237 ResId fddiPATHIndex
;
238 u_long fddiPATHSbaPayload
;
239 u_long fddiPATHSbaOverhead
;
240 /* fddiPATHConfiguration is built on demand */
241 /* u_long fddiPATHConfiguration ; */
242 Timer fddiPATHT_Rmode
;
243 u_long fddiPATHSbaAvailable
;
244 Timer_2 fddiPATHTVXLowerBound
;
245 Timer_2 fddiPATHT_MaxLowerBound
;
246 Timer_2 fddiPATHMaxT_Req
;
252 SMTEnum fddiPORTMy_Type
;
253 SMTEnum fddiPORTNeighborType
;
254 u_char fddiPORTConnectionPolicies
;
258 } fddiPORTMacIndicated
;
259 SMTEnum fddiPORTCurrentPath
;
260 /* must be 4: is 32 bit in SMT format
266 u_char fddiPORTRequestedPaths
[4] ;
267 u_short fddiPORTMACPlacement
;
268 u_char fddiPORTAvailablePaths
;
269 u_char fddiPORTConnectionCapabilities
;
270 SMTEnum fddiPORTPMDClass
;
271 ResId fddiPORTIndex
;
274 SMTEnum fddiPORTMaint_LS
;
275 SMTEnum fddiPORTPC_LS
;
276 u_char fddiPORTBS_Flag
;
279 Counter fddiPORTLCTFail_Ct
;
280 Counter fddiPORTEBError_Ct
;
281 Counter fddiPORTOldEBError_Ct
;
284 Counter fddiPORTLem_Reject_Ct
;
285 Counter fddiPORTLem_Ct
;
286 u_char fddiPORTLer_Estimate
;
287 u_char fddiPORTLer_Cutoff
;
288 u_char fddiPORTLer_Alarm
;
291 SMTEnum fddiPORTConnectState
;
292 SMTEnum fddiPORTPCMState
; /* real value */
293 SMTEnum fddiPORTPCMStateX
; /* value for MIB */
294 SMTEnum fddiPORTPC_Withhold
;
295 SMTFlag fddiPORTHardwarePresent
;
296 u_char fddiPORTLerFlag
;
298 u_char fddiPORTMultiple_U
; /* private */
299 u_char fddiPORTMultiple_P
; /* private */
300 u_char fddiPORTEB_Condition
; /* private */
303 Counter fddiPRIVECF_Req_Rx
; /* ECF req received */
304 Counter fddiPRIVECF_Reply_Rx
; /* ECF repl received */
305 Counter fddiPRIVECF_Req_Tx
; /* ECF req transm */
306 Counter fddiPRIVECF_Reply_Tx
; /* ECF repl transm */
307 Counter fddiPRIVPMF_Get_Rx
; /* PMF Get rec */
308 Counter fddiPRIVPMF_Set_Rx
; /* PMF Set rec */
309 Counter fddiPRIVRDF_Rx
; /* RDF received */
310 Counter fddiPRIVRDF_Tx
; /* RDF transmitted */
315 * OIDs for statistics
317 #define SMT_OID_CF_STATE 1 /* fddiSMTCF_State */
318 #define SMT_OID_PCM_STATE_A 2 /* fddiPORTPCMState port A */
319 #define SMT_OID_PCM_STATE_B 17 /* fddiPORTPCMState port B */
320 #define SMT_OID_RMT_STATE 3 /* fddiMACRMTState */
321 #define SMT_OID_UNA 4 /* fddiMACUpstreamNbr */
322 #define SMT_OID_DNA 5 /* fddiMACOldDownstreamNbr */
323 #define SMT_OID_ERROR_CT 6 /* fddiMACError_Ct */
324 #define SMT_OID_LOST_CT 7 /* fddiMACLost_Ct */
325 #define SMT_OID_LEM_CT 8 /* fddiPORTLem_Ct */
326 #define SMT_OID_LEM_CT_A 11 /* fddiPORTLem_Ct port A */
327 #define SMT_OID_LEM_CT_B 12 /* fddiPORTLem_Ct port B */
328 #define SMT_OID_LCT_FAIL_CT 9 /* fddiPORTLCTFail_Ct */
329 #define SMT_OID_LCT_FAIL_CT_A 13 /* fddiPORTLCTFail_Ct port A */
330 #define SMT_OID_LCT_FAIL_CT_B 14 /* fddiPORTLCTFail_Ct port B */
331 #define SMT_OID_LEM_REJECT_CT 10 /* fddiPORTLem_Reject_Ct */
332 #define SMT_OID_LEM_REJECT_CT_A 15 /* fddiPORTLem_Reject_Ct port A */
333 #define SMT_OID_LEM_REJECT_CT_B 16 /* fddiPORTLem_Reject_Ct port B */
338 #define SMT_OID_ECF_REQ_RX 20 /* ECF requests received */
339 #define SMT_OID_ECF_REPLY_RX 21 /* ECF replies received */
340 #define SMT_OID_ECF_REQ_TX 22 /* ECF requests transmitted */
341 #define SMT_OID_ECF_REPLY_TX 23 /* ECF replies transmitted */
342 #define SMT_OID_PMF_GET_RX 24 /* PMF get requests received */
343 #define SMT_OID_PMF_SET_RX 25 /* PMF set requests received */
344 #define SMT_OID_RDF_RX 26 /* RDF received */
345 #define SMT_OID_RDF_TX 27 /* RDF transmitted */