|
|
1.1 ! root 1: #ifndef _SYS_DLPI_H ! 2: #define _SYS_DLPI_H ! 3: ! 4: typedef unsigned long ulong; ! 5: typedef unsigned short ushort; ! 6: ! 7: // ! 8: // DLPI revision definition history ! 9: // ! 10: ! 11: #define DL_VERSION_2 0x02 // version of dlpi March 12,1991 ! 12: #define DL_CURRENT_VERSION DL_VERSION_2 // current version of dlpi ! 13: ! 14: // ! 15: // Primitives for Local Management Services ! 16: // ! 17: ! 18: #define DL_INFO_REQ 0x00 // Information Req, LLI compatibility ! 19: #define DL_INFO_ACK 0x03 // Information Ack, LLI compatibility ! 20: #define DL_ATTACH_REQ 0x0b // Attach a PPA ! 21: #define DL_DETACH_REQ 0x0c // Detach a PPA ! 22: #define DL_BIND_REQ 0x01 // Bind dlsap address, LLI compatibility ! 23: #define DL_BIND_ACK 0x04 // Dlsap address bound, LLI compatibility ! 24: #define DL_UNBIND_REQ 0x02 // Unbind dlsap address, LLI compatibility ! 25: #define DL_OK_ACK 0x06 // Success acknowledgment, LLI compatibility ! 26: #define DL_ERROR_ACK 0x05 // Error acknowledgment, LLI compatibility ! 27: #define DL_SUBS_BIND_REQ 0x1b // Bind Subsequent DLSAP address ! 28: #define DL_SUBS_BIND_ACK 0x1c // Subsequent DLSAP address bound ! 29: #define DL_SUBS_UNBIND_REQ 0x15 // Subsequent unbind ! 30: #define DL_ENABMULTI_REQ 0x1d // Enable multicast addresses ! 31: #define DL_DISABMULTI_REQ 0x1e // Disable multicast addresses ! 32: #define DL_PROMISCON_REQ 0x1f // Turn on promiscuous mode ! 33: #define DL_PROMISCOFF_REQ 0x20 // Turn off promiscuous mode ! 34: ! 35: // ! 36: // Primitives used for Connectionless Service ! 37: // ! 38: ! 39: #define DL_UNITDATA_REQ 0x07 // datagram send request, LLI compatibility ! 40: #define DL_UNITDATA_IND 0x08 // datagram receive indication, LLI compatibility ! 41: #define DL_UDERROR_IND 0x09 // datagram error indication, LLI compatibility ! 42: #define DL_UDQOS_REQ 0x0a // set QOS for subsequent datagram transmissions ! 43: ! 44: // ! 45: // Primitives used for Connection-Oriented Service ! 46: // ! 47: ! 48: #define DL_CONNECT_REQ 0x0d // Connect request ! 49: #define DL_CONNECT_IND 0x0e // Incoming connect indication ! 50: #define DL_CONNECT_RES 0x0f // Accept previous connect indication ! 51: #define DL_CONNECT_CON 0x10 // Connection established ! 52: ! 53: #define DL_TOKEN_REQ 0x11 // Passoff token request ! 54: #define DL_TOKEN_ACK 0x12 // Passoff token ack ! 55: ! 56: #define DL_DISCONNECT_REQ 0x13 // Disconnect request ! 57: #define DL_DISCONNECT_IND 0x14 // Disconnect indication ! 58: ! 59: #define DL_RESET_REQ 0x17 // Reset service request ! 60: #define DL_RESET_IND 0x18 // Incoming reset indication ! 61: #define DL_RESET_RES 0x19 // Complete reset processing ! 62: #define DL_RESET_CON 0x1a // Reset processing complete ! 63: ! 64: // ! 65: // Primitives used for Acknowledged Connectionless Service ! 66: // ! 67: ! 68: #define DL_DATA_ACK_REQ 0x21 // data unit transmission request ! 69: #define DL_DATA_ACK_IND 0x22 // Arrival of a command PDU ! 70: #define DL_DATA_ACK_STATUS_IND 0x23 // Status indication of DATA_ACK_REQ ! 71: #define DL_REPLY_REQ 0x24 // Request a DLSDU from the remote ! 72: #define DL_REPLY_IND 0x25 // Arrival of a command PDU ! 73: #define DL_REPLY_STATUS_IND 0x26 // Status indication of REPLY_REQ ! 74: #define DL_REPLY_UPDATE_REQ 0x27 // Hold a DLSDU for transmission ! 75: #define DL_REPLY_UPDATE_STATUS_IND 0x28 // Status of REPLY_UPDATE req ! 76: ! 77: // ! 78: // Primitives used for XID and TEST operation ! 79: // ! 80: ! 81: #define DL_XID_REQ 0x29 // Request to send an XID PDU ! 82: #define DL_XID_IND 0x2a // Arrival of an XID PDU ! 83: #define DL_XID_RES 0x2b // request to send a response XID PDU ! 84: #define DL_XID_CON 0x2c // Arrival of a response XID PDU ! 85: #define DL_TEST_REQ 0x2d // Test command request ! 86: #define DL_TEST_IND 0x2e // Test response indication ! 87: #define DL_TEST_RES 0x2f // Test request ! 88: #define DL_TEST_CON 0x30 // Test Confirmation ! 89: ! 90: // ! 91: // Primitives to get and set the physical address, and to get ! 92: // Statistics ! 93: // ! 94: ! 95: #define DL_PHYS_ADDR_REQ 0x31 // Request to get physical addr ! 96: #define DL_PHYS_ADDR_ACK 0x32 // Return physical addr ! 97: #define DL_SET_PHYS_ADDR_REQ 0x33 // set physical addr ! 98: #define DL_GET_STATISTICS_REQ 0x34 // Request to get statistics ! 99: #define DL_GET_STATISTICS_ACK 0x35 // Return statistics ! 100: ! 101: // ! 102: // Primitives to use performance modifications ! 103: // ! 104: ! 105: #define DL_SHOULD_PUT_REQ 0xf0 ! 106: ! 107: // ! 108: // Primitives to get at low level card information ! 109: // ! 110: ! 111: #define DL_ADAPTER_INFO_REQ 0xf1 ! 112: #define DL_ADAPTER_INFO_ACK 0xf2 ! 113: ! 114: // ! 115: // DLPI interface states ! 116: // ! 117: ! 118: #define DL_UNATTACHED 0x04 // PPA not attached ! 119: #define DL_ATTACH_PENDING 0x05 // Waiting ack of DL_ATTACH_REQ ! 120: #define DL_DETACH_PENDING 0x06 // Waiting ack of DL_DETACH_REQ ! 121: #define DL_UNBOUND 0x00 // PPA attached, LLI compatibility ! 122: #define DL_BIND_PENDING 0x01 // Waiting ack of DL_BIND_REQ, LLI compatibility ! 123: #define DL_UNBIND_PENDING 0x02 // Waiting ack of DL_UNBIND_REQ, LLI compatibility ! 124: #define DL_IDLE 0x03 // dlsap bound, awaiting use, LLI compatibility ! 125: #define DL_UDQOS_PENDING 0x07 // Waiting ack of DL_UDQOS_REQ ! 126: #define DL_OUTCON_PENDING 0x08 // outgoing connection, awaiting DL_CONN_CON ! 127: #define DL_INCON_PENDING 0x09 // incoming connection, awaiting DL_CONN_RES ! 128: #define DL_CONN_RES_PENDING 0x0a // Waiting ack of DL_CONNECT_RES ! 129: #define DL_DATAXFER 0x0b // connection-oriented data transfer ! 130: #define DL_USER_RESET_PENDING 0x0c // user initiated reset, awaiting DL_RESET_CON ! 131: #define DL_PROV_RESET_PENDING 0x0d // provider initiated reset, awaiting DL_RESET_RES ! 132: #define DL_RESET_RES_PENDING 0x0e // Waiting ack of DL_RESET_RES ! 133: #define DL_DISCON8_PENDING 0x0f // Waiting ack of DL_DISC_REQ when in DL_OUTCON_PENDING ! 134: #define DL_DISCON9_PENDING 0x10 // Waiting ack of DL_DISC_REQ when in DL_INCON_PENDING ! 135: #define DL_DISCON11_PENDING 0x11 // Waiting ack of DL_DISC_REQ when in DL_DATAXFER ! 136: #define DL_DISCON12_PENDING 0x12 // Waiting ack of DL_DISC_REQ when in DL_USER_RESET_PENDING ! 137: #define DL_DISCON13_PENDING 0x13 // Waiting ack of DL_DISC_REQ when in DL_DL_PROV_RESET_PENDING ! 138: #define DL_SUBS_BIND_PND 0x14 // Waiting ack of DL_SUBS_BIND_REQ ! 139: #define DL_SUBS_UNBIND_PND 0x15 // Waiting ack of DL_SUBS_UNBIND_REQ ! 140: #define DL_INTERRUPT_PENDING 0x16 // awaiting DL_INTERRUPT_CON ! 141: ! 142: // ! 143: // DL_ERROR_ACK error return values ! 144: // ! 145: ! 146: ! 147: #define DL_ACCESS 0x02 // Improper permissions for request, LLI compatibility ! 148: #define DL_BADADDR 0x01 // DLSAP address in improper format or invalid ! 149: #define DL_BADCORR 0x05 // Sequence number not from outstanding DL_CONN_IND ! 150: #define DL_BADDATA 0x06 // User data exceeded provider limit ! 151: #define DL_BADPPA 0x08 // Specified PPA was invalid ! 152: #define DL_BADPRIM 0x09 // Primitive received is not known by DLS provider ! 153: #define DL_BADQOSPARAM 0x0a // QOS parameters contained invalid values ! 154: #define DL_BADQOSTYPE 0x0b // QOS structure type is unknown or unsupported ! 155: #define DL_BADSAP 0x00 // Bad LSAP selector, LLI compatibility ! 156: #define DL_BADTOKEN 0x0c // Token used not associated with an active stream ! 157: #define DL_BOUND 0x0d // Attempted second bind with dl_max_conind or ! 158: // dl_conn_mgmt > 0 on same DLSAP or PPA ! 159: #define DL_INITFAILED 0x0e // Physical Link initialization failed ! 160: #define DL_NOADDR 0x0f // Provider couldn't allocate alternate address ! 161: #define DL_NOTINIT 0x10 // Physical Link not initialized ! 162: #define DL_OUTSTATE 0x03 // Primitive issued in improper state, LLI compatibility ! 163: #define DL_SYSERR 0x04 // UNIX system error occurred, LLI compatibility ! 164: #define DL_UNSUPPORTED 0x07 // Requested service not supplied by provider ! 165: #define DL_UNDELIVERABLE 0x11 // Previous data unit could not be delivered ! 166: #define DL_NOTSUPPORTED 0x12 // Primitive is known bu not supported by DLS provider ! 167: #define DL_TOOMANY 0x13 // limit exceeded ! 168: #define DL_NOTENAB 0x14 // Promiscuous mode not enabled ! 169: #define DL_BUSY 0x15 // Other streams for a particular PPA in the ! 170: // post-attached state ! 171: #define DL_NOAUTO 0x16 // Automatic handling of XID & TEST responses ! 172: // not supported ! 173: #define DL_NOXIDAUTO 0x17 // Automatic handling of XID not supported ! 174: #define DL_NOTESTAUTO 0x18 // Automatic handling of TEST not supported ! 175: #define DL_XIDAUTO 0x19 // Automatic handling of XID response ! 176: #define DL_TESTAUTO 0x1a // Automatic handling of TEST response ! 177: #define DL_PENDING 0x1b // pending outstanding connect indications ! 178: ! 179: // ! 180: // DLPI media types supported ! 181: // ! 182: ! 183: #define DL_CSMACD 0x0 // IEEE 802.3 CSMA/CD network, LLI Compatibility ! 184: #define DL_TPB 0x1 // IEEE 802.4 Token Passing Bus, LLI Compatibility ! 185: #define DL_TPR 0x2 // IEEE 802.5 Token Passing Ring, LLI Compatibility ! 186: #define DL_METRO 0x3 // IEEE 802.6 Metro Net, LLI Compatibility ! 187: #define DL_ETHER 0x4 // Ethernet Bus, LLI Compatibility ! 188: #define DL_HDLC 0x05 // ISO HDLC protocol support, bit synchronous ! 189: #define DL_CHAR 0x06 // Character Synchronous protocol support, eg BISYNC ! 190: #define DL_CTCA 0x07 // IBM Channel-to-Channel Adapter ! 191: #define DL_FDDI 0x08 // Fiber Distributed data interface ! 192: #define DL_OTHER 0x09 // Any other medium not listed above ! 193: #define DL_ARCNET 0x0a // Raw arcnet packets ! 194: #define DL_ASYN 0x0b // Bit Asynchronous Serial Interface ! 195: ! 196: // ! 197: // DLPI provider service supported. ! 198: // These must be allowed to be bitwise-OR for dl_service_mode in ! 199: // DL_INFO_ACK. ! 200: ! 201: // ! 202: #define DL_CODLS 0x01 // support connection-oriented service ! 203: #define DL_CLDLS 0x02 // support connectionless data link service ! 204: #define DL_ACLDLS 0x04 // support acknowledged connectionless service ! 205: ! 206: // ! 207: // DLPI provider style. ! 208: // The DLPI provider style which determines whether a provider ! 209: // requires a DL_ATTACH_REQ to inform the provider which PPA ! 210: // user messages should be sent/received on. ! 211: // ! 212: ! 213: #define DL_STYLE1 0x0500 // PPA is implicitly bound by open(2) ! 214: #define DL_STYLE2 0x0501 // PPA must be explicitly bound via DL_ATTACH_REQ ! 215: ! 216: // ! 217: // DLPI Originator for Disconnect and Resets ! 218: // ! 219: ! 220: #define DL_PROVIDER 0x700 ! 221: #define DL_USER 0x701 ! 222: ! 223: // ! 224: // DLPI Disconnect Reasons ! 225: // ! 226: ! 227: #define DL_CONREJ_DEST_UNKNOWN 0x0800 ! 228: #define DL_CONREJ_DEST_UNREACH_PERMANENT 0x0801 ! 229: #define DL_CONREJ_DEST_UNREACH_TRANSIENT 0x0802 ! 230: #define DL_CONREJ_QOS_UNAVAIL_PERMANENT 0x0803 ! 231: #define DL_CONREJ_QOS_UNAVAIL_TRANSIENT 0x0804 ! 232: #define DL_CONREJ_PERMANENT_COND 0x0805 ! 233: #define DL_CONREJ_TRANSIENT_COND 0x0806 ! 234: #define DL_DISC_ABNORMAL_CONDITION 0x0807 ! 235: #define DL_DISC_NORMAL_CONDITION 0x0808 ! 236: #define DL_DISC_PERMANENT_CONDITION 0x0809 ! 237: #define DL_DISC_TRANSIENT_CONDITION 0x080a ! 238: #define DL_DISC_UNSPECIFIED 0x080b ! 239: ! 240: // ! 241: // DLPI Reset Reasons ! 242: // ! 243: ! 244: #define DL_RESET_FLOW_CONTROL 0x0900 ! 245: #define DL_RESET_LINK_ERROR 0x0901 ! 246: #define DL_RESET_RESYNCH 0x0902 ! 247: ! 248: // ! 249: // DLPI status values for acknowledged connectionless data transfer ! 250: // ! 251: ! 252: #define DL_CMD_MASK 0x0f // mask for command portion of status ! 253: #define DL_CMD_OK 0x00 // Command Accepted ! 254: #define DL_CMD_RS 0x01 // Unimplemented or inactivated service ! 255: #define DL_CMD_UE 0x05 // Data Link User interface error ! 256: #define DL_CMD_PE 0x06 // Protocol error ! 257: #define DL_CMD_IP 0x07 // Permanent implementation dependent error ! 258: #define DL_CMD_UN 0x09 // Resources temporarily unavailable ! 259: #define DL_CMD_IT 0x0f // Temporary implementation dependent error ! 260: #define DL_RSP_MASK 0xf0 // mask for response portion of status ! 261: #define DL_RSP_OK 0x00 // Response DLSDU present ! 262: #define DL_RSP_RS 0x10 // Unimplemented or inactivated service ! 263: #define DL_RSP_NE 0x30 // Response DLSDU never submitted ! 264: #define DL_RSP_NR 0x40 // Response DLSDU not requested ! 265: #define DL_RSP_UE 0x50 // Data Link User interface error ! 266: #define DL_RSP_IP 0x70 // Permanent implementation dependent error ! 267: #define DL_RSP_UN 0x90 // Resources temporarily unavailable ! 268: #define DL_RSP_IT 0xf0 // Temporary implementation dependent error ! 269: ! 270: // ! 271: // Service Class values for acknowledged connectionless data transfer ! 272: // ! 273: ! 274: #define DL_RQST_RSP 0x01 // Use acknowledge capability in MAC sublayer ! 275: #define DL_RQST_NORSP 0x02 // No acknowledgement service requested ! 276: ! 277: // ! 278: // DLPI address type definition ! 279: // ! 280: ! 281: #define DL_FACT_PHYS_ADDR 0x01 // factory physical address ! 282: #define DL_CURR_PHYS_ADDR 0x02 // current physical address ! 283: ! 284: // ! 285: // DLPI flag definitions ! 286: // ! 287: ! 288: #define DL_POLL_FINAL 0x01 // if set, indicates poll/final bit set ! 289: ! 290: // ! 291: // XID and TEST responses supported by the provider ! 292: // ! 293: ! 294: #define DL_AUTO_XID 0x01 // provider will respond to XID ! 295: #define DL_AUTO_TEST 0x02 // provider will respond to TEST ! 296: ! 297: // ! 298: // Subsequent bind type ! 299: // ! 300: ! 301: #define DL_PEER_BIND 0x01 // subsequent bind on a peer addr ! 302: #define DL_HIERARCHICAL_BIND 0x02 // subs_bind on a hierarchical addr ! 303: ! 304: // ! 305: // DLPI promiscuous mode definitions ! 306: // ! 307: ! 308: #define DL_PROMISC_PHYS 0x01 // promiscuous mode at phys level ! 309: #define DL_PROMISC_SAP 0x02 // promiscuous mode at sap level ! 310: #define DL_PROMISC_MULTI 0x03 // promiscuous mode for multicast ! 311: ! 312: // ! 313: // DLPI Quality Of Service definition for use in QOS structure definitions. ! 314: // The QOS structures are used in connection establishment, DL_INFO_ACK, ! 315: // and setting connectionless QOS values. ! 316: // ! 317: ! 318: ! 319: // ! 320: // Throughput ! 321: // ! 322: // This parameter is specified for both directions. ! 323: // ! 324: ! 325: typedef struct { ! 326: long dl_target_value; // desired bits/second desired ! 327: long dl_accept_value; // min. acceptable bits/second ! 328: } dl_through_t; ! 329: ! 330: // ! 331: // transit delay specification ! 332: // ! 333: // This parameter is specified for both directions. ! 334: // expressed in milliseconds assuming a DLSDU size of 128 octets. ! 335: // The scaling of the value to the current DLSDU size is provider dependent. ! 336: // ! 337: ! 338: typedef struct { ! 339: long dl_target_value; // desired value of service ! 340: long dl_accept_value; // min. acceptable value of service ! 341: } dl_transdelay_t; ! 342: ! 343: // ! 344: // priority specification ! 345: // priority range is 0-100, with 0 being highest value. ! 346: // ! 347: ! 348: typedef struct { ! 349: long dl_min; ! 350: long dl_max; ! 351: } dl_priority_t; ! 352: ! 353: // ! 354: // protection specification ! 355: // ! 356: ! 357: #define DL_NONE 0x0B01 // no protection supplied ! 358: #define DL_MONITOR 0x0B02 // protection against passive monitoring ! 359: #define DL_MAXIMUM 0x0B03 // protection against modification, replay, ! 360: // addition, or deletion ! 361: typedef struct { ! 362: long dl_min; ! 363: long dl_max; ! 364: } dl_protect_t; ! 365: ! 366: // ! 367: // Resilience specification ! 368: // probabilities are scaled by a factor of 10,000 with a time interval ! 369: // of 10,000 seconds. ! 370: // ! 371: ! 372: typedef struct { ! 373: long dl_disc_prob; // probability of provider init DISC ! 374: long dl_reset_prob; // probability of provider init RESET ! 375: } dl_resilience_t; ! 376: ! 377: // ! 378: // QOS type definition to be used for negotiation with the ! 379: // remote end of a connection, or a connectionless unitdata request. ! 380: // There are two type definitions to handle the negotiation ! 381: // process at connection establishment. The typedef dl_qos_neg_t ! 382: // is used to present a range for parameters. This is used ! 383: // in the DL_CONNECT_REQ and DL_CONNECT_IND messages. The typedef ! 384: // dl_qos_sel_t is used to select a specific value for the QOS ! 385: // parameters. This is used in the DL_CONNECT_RES, DL_CONNECT_CON, ! 386: // and DL_INFO_ACK messages to define the selected QOS parameters ! 387: // for a connection. ! 388: // ! 389: // NOTE ! 390: // A DataLink provider which has unknown values for any of the fields ! 391: // will use a value of DL_UNKNOWN for all values in the fields. ! 392: // ! 393: // NOTE ! 394: // A QOS parameter value of DL_QOS_DONT_CARE informs the DLS ! 395: // provider the user requesting this value doesn't care ! 396: // what the QOS parameter is set to. This value becomes the ! 397: // least possible value in the range of QOS parameters. ! 398: // The order of the QOS parameter range is then: ! 399: // ! 400: // DL_QOS_DONT_CARE < 0 < MAZIMUM QOS VALUE ! 401: // ! 402: ! 403: #define DL_UNKNOWN -1 ! 404: #define DL_QOS_DONT_CARE -2 ! 405: ! 406: // ! 407: // Every QOS structure has the first 4 bytes containing a type ! 408: // field, denoting the definition of the rest of the structure. ! 409: // This is used in the same manner has the dl_primitive variable ! 410: // is in messages. ! 411: // ! 412: // The following list is the defined QOS structure type values and structures. ! 413: // ! 414: ! 415: #define DL_QOS_CO_RANGE1 0x0101 // QOS range struct. for Connection modeservice ! 416: #define DL_QOS_CO_SEL1 0x0102 // QOS selection structure ! 417: #define DL_QOS_CL_RANGE1 0x0103 // QOS range struct. for connectionless ! 418: #define DL_QOS_CL_SEL1 0x0104 // QOS selection for connectionless mode ! 419: ! 420: typedef struct { ! 421: unsigned long dl_qos_type; ! 422: dl_through_t dl_rcv_throughput; // desired and acceptable ! 423: dl_transdelay_t dl_rcv_trans_delay; // desired and acceptable ! 424: dl_through_t dl_xmt_throughput; ! 425: dl_transdelay_t dl_xmt_trans_delay; ! 426: dl_priority_t dl_priority; // min and max values ! 427: dl_protect_t dl_protection; // min and max values ! 428: long dl_residual_error; ! 429: dl_resilience_t dl_resilience; ! 430: } dl_qos_co_range1_t; ! 431: ! 432: typedef struct { ! 433: unsigned long dl_qos_type; ! 434: long dl_rcv_throughput; ! 435: long dl_rcv_trans_delay; ! 436: long dl_xmt_throughput; ! 437: long dl_xmt_trans_delay; ! 438: long dl_priority; ! 439: long dl_protection; ! 440: long dl_residual_error; ! 441: dl_resilience_t dl_resilience; ! 442: } dl_qos_co_sel1_t; ! 443: ! 444: typedef struct { ! 445: unsigned long dl_qos_type; ! 446: dl_transdelay_t dl_trans_delay; ! 447: dl_priority_t dl_priority; ! 448: dl_protect_t dl_protection; ! 449: long dl_residual_error; ! 450: } dl_qos_cl_range1_t; ! 451: ! 452: typedef struct { ! 453: unsigned long dl_qos_type; ! 454: long dl_trans_delay; ! 455: long dl_priority; ! 456: long dl_protection; ! 457: long dl_residual_error; ! 458: } dl_qos_cl_sel1_t; ! 459: ! 460: // ! 461: // DLPI interface primitive definitions. ! 462: // ! 463: // Each primitive is sent as a stream message. It is possible that ! 464: // the messages may be viewed as a sequence of bytes that have the ! 465: // following form without any padding. The structure definition ! 466: // of the following messages may have to change depending on the ! 467: // underlying hardware architecture and crossing of a hardware ! 468: // boundary with a differenct hardware architecture. ! 469: // ! 470: // Fields in the primitives having a name of the form ! 471: // dl_reserved cannot be used and have the value of ! 472: // binary zero, no bits turned on. ! 473: // ! 474: // Each message has the name defined followed by the ! 475: // stream message type (M_PROTO, M_PCPROTO, M_DATA) ! 476: // ! 477: ! 478: ! 479: // ! 480: // LOCAL MANAGEMENT SERVICE PRIMITIVES ! 481: // ! 482: ! 483: ! 484: // ! 485: // DL_INFO_REQ, M_PCPROTO type ! 486: // ! 487: ! 488: typedef struct { ! 489: unsigned long dl_primitive; // set to DL_INFO_REQ ! 490: } dl_info_req_t; ! 491: ! 492: // ! 493: // DL_INFO_ACK, M_PCPROTO type ! 494: // ! 495: ! 496: typedef struct { ! 497: unsigned long dl_primitive; // set to DL_INFO_ACK ! 498: unsigned long dl_max_sdu; // Max bytes in a DLSDU ! 499: unsigned long dl_min_sdu; // Min bytes in a DLSDU ! 500: unsigned long dl_addr_length; // length of DLSAP address ! 501: unsigned long dl_mac_type; // type of medium supported ! 502: unsigned long dl_reserved; // value set to zero ! 503: unsigned long dl_current_state; // state of DLPI interface ! 504: long dl_sap_length; // current length of SAP part ! 505: // of dlsap address ! 506: unsigned long dl_service_mode; // CO, CL or ACL ! 507: unsigned long dl_qos_length; // length of qos values ! 508: unsigned long dl_qos_offset; // offset from beg. of block ! 509: unsigned long dl_qos_range_length; // available range of qos ! 510: unsigned long dl_qos_range_offset; // offset from beg. of block ! 511: unsigned long dl_provider_style; // style1 or style2 ! 512: unsigned long dl_addr_offset; // offset of the dlsap addr ! 513: unsigned long dl_version; // version number ! 514: unsigned long dl_brdcst_addr_length; // length of broadcast addr ! 515: unsigned long dl_brdcst_addr_offset; // offset from beg. of block ! 516: unsigned long dl_growth; // set to zero ! 517: } dl_info_ack_t; ! 518: ! 519: // ! 520: // DL_ATTACH_REQ, M_PROTO type ! 521: // ! 522: ! 523: typedef struct { ! 524: unsigned long dl_primitive; // set to DL_ATTACH_REQ ! 525: unsigned long dl_ppa; // id of the PPA ! 526: } dl_attach_req_t; ! 527: ! 528: // ! 529: // DL_DETACH_REQ, M_PROTO type ! 530: // ! 531: ! 532: typedef struct { ! 533: unsigned long dl_primitive; // set to DL_DETACH_REQ ! 534: } dl_detach_req_t; ! 535: ! 536: // ! 537: // DL_BIND_REQ, M_PROTO type ! 538: // ! 539: ! 540: typedef struct { ! 541: unsigned long dl_primitive; // set to DL_BIND_REQ ! 542: unsigned long dl_sap; // info to identify dlsap addr ! 543: unsigned long dl_max_conind; // max # of outstanding con_ind ! 544: unsigned short dl_service_mode;// CO, CL or ACL ! 545: unsigned short dl_conn_mgmt; // if non-zero, is con-mgmt stream ! 546: unsigned long dl_xidtest_flg; // if set to 1 indicates automatic ! 547: // initiation of test and xid frames ! 548: } dl_bind_req_t; ! 549: ! 550: // ! 551: // DL_BIND_ACK, M_PCPROTO type ! 552: // ! 553: ! 554: typedef struct { ! 555: unsigned long dl_primitive; // DL_BIND_ACK ! 556: unsigned long dl_sap; // DLSAP addr info ! 557: unsigned long dl_addr_length; // length of complete DLSAP addr ! 558: unsigned long dl_addr_offset; // offset from beginning of M_PCPROTO ! 559: unsigned long dl_max_conind; // allowed max. # of con-ind ! 560: unsigned long dl_xidtest_flg; // responses supported by provider ! 561: } dl_bind_ack_t; ! 562: ! 563: // ! 564: // DL_SUBS_BIND_REQ, M_PROTO type ! 565: // ! 566: ! 567: typedef struct { ! 568: unsigned long dl_primitive; // DL_SUBS_BIND_REQ ! 569: unsigned long dl_subs_sap_offset; // offset of subs_sap ! 570: unsigned long dl_subs_sap_length; // length of subs_sap ! 571: unsigned long dl_subs_bind_class; // peer or hierarchical ! 572: } dl_subs_bind_req_t; ! 573: ! 574: // ! 575: // DL_SUBS_BIND_ACK, M_PCPROTO type ! 576: // ! 577: ! 578: typedef struct { ! 579: unsigned long dl_primitive; // DL_SUBS_BIND_ACK ! 580: unsigned long dl_subs_sap_offset; // offset of subs_sap ! 581: unsigned long dl_subs_sap_len; // length of subs_sap ! 582: } dl_subs_bind_ack_t; ! 583: ! 584: // ! 585: // DL_UNBIND_REQ, M_PROTO type ! 586: // ! 587: ! 588: typedef struct { ! 589: unsigned long dl_primitive; // DL_UNBIND_REQ ! 590: } dl_unbind_req_t; ! 591: ! 592: // ! 593: // DL_SUBS_UNBIND_REQ, M_PROTO type ! 594: // ! 595: ! 596: typedef struct { ! 597: unsigned long dl_primitive; // DL_SUBS_UNBIND_REQ ! 598: unsigned long dl_subs_sap_offset; // offset of subs_sap ! 599: unsigned long dl_subs_sap_length; // length of subs_sap ! 600: } dl_subs_unbind_req_t; ! 601: ! 602: // ! 603: // DL_OK_ACK, M_PCPROTO type ! 604: // ! 605: ! 606: typedef struct { ! 607: unsigned long dl_primitive; // DL_OK_ACK ! 608: unsigned long dl_correct_primitive; // primitive being acknokwledged ! 609: } dl_ok_ack_t; ! 610: ! 611: // ! 612: // DL_ERROR_ACK, M_PCPROTO type ! 613: // ! 614: ! 615: typedef struct { ! 616: unsigned long dl_primitive; // DL_ERROR_ACK ! 617: unsigned long dl_error_primitive; // primitive in error ! 618: unsigned long dl_errno; // DLPI error code ! 619: unsigned long dl_unix_errno; // UNIX system error code ! 620: } dl_error_ack_t; ! 621: ! 622: // ! 623: // DL_ENABMULTI_REQ, M_PROTO type ! 624: // ! 625: ! 626: typedef struct { ! 627: unsigned long dl_primitive; // DL_ENABMULTI_REQ ! 628: unsigned long dl_addr_length; // length of multicast address ! 629: unsigned long dl_addr_offset; // offset from beg. of M_PROTO block ! 630: } dl_enabmulti_req_t; ! 631: ! 632: // ! 633: // DL_DISABMULTI_REQ, M_PROTO type ! 634: // ! 635: ! 636: typedef struct { ! 637: unsigned long dl_primitive; // DL_DISABMULTI_REQ ! 638: unsigned long dl_addr_length; // length of multicast address ! 639: unsigned long dl_addr_offset; // offset from beg. of M_PROTO block ! 640: } dl_disabmulti_req_t; ! 641: ! 642: // ! 643: // DL_PROMISCON_REQ, M_PROTO type ! 644: // ! 645: ! 646: typedef struct { ! 647: unsigned long dl_primitive; // DL_PROMISCON_REQ ! 648: unsigned long dl_level; // physical,SAP level or ALLmulticast ! 649: } dl_promiscon_req_t; ! 650: ! 651: // ! 652: // DL_PROMISCOFF_REQ, M_PROTO type ! 653: // ! 654: ! 655: typedef struct { ! 656: unsigned long dl_primitive; // DL_PROMISCOFF_REQ ! 657: unsigned long dl_level; // physical,SAP level or ALLmulticast ! 658: } dl_promiscoff_req_t; ! 659: ! 660: // ! 661: // Primitives to get and set the Physical address ! 662: // ! 663: ! 664: ! 665: // ! 666: // DL_PHYS_ADDR_REQ, M_PROTO type ! 667: // ! 668: ! 669: typedef struct { ! 670: unsigned long dl_primitive; // DL_PHYS_ADDR_REQ ! 671: unsigned long dl_addr_type; // factory or current physical addr ! 672: } dl_phys_addr_req_t; ! 673: ! 674: // ! 675: // DL_PHYS_ADDR_ACK, M_PCPROTO type ! 676: // ! 677: ! 678: typedef struct { ! 679: unsigned long dl_primitive; // DL_PHYS_ADDR_ACK ! 680: unsigned long dl_addr_length; // length of physical address ! 681: unsigned long dl_addr_offset; // offset from beg. of block ! 682: } dl_phys_addr_ack_t; ! 683: ! 684: // ! 685: // DL_SET_PHYS_ADDR_REQ, M_PROTO type ! 686: // ! 687: ! 688: typedef struct { ! 689: unsigned long dl_primitive; // DL_SET_PHYS_ADDR_REQ ! 690: unsigned long dl_addr_length; // length of physical address ! 691: unsigned long dl_addr_offset; // offset from beg. of block ! 692: } dl_set_phys_addr_req_t; ! 693: ! 694: // ! 695: // Primitives to get statistics ! 696: // ! 697: ! 698: ! 699: // ! 700: // DL_GET_STATISTICS_REQ, M_PROTO type ! 701: // ! 702: ! 703: typedef struct { ! 704: unsigned long dl_primitive; // DL_GET_STATISTICS_REQ ! 705: } dl_get_statistics_req_t; ! 706: ! 707: // ! 708: // DL_GET_STATISTICS_ACK, M_PCPROTO type ! 709: // ! 710: ! 711: typedef struct { ! 712: unsigned long dl_primitive; // DL_GET_STATISTICS_ACK ! 713: unsigned long dl_stat_length; // length of statistics structure ! 714: unsigned long dl_stat_offset; // offset from beg. of block ! 715: } dl_get_statistics_ack_t; ! 716: ! 717: // ! 718: // CONNECTION-ORIENTED SERVICE PRIMITIVES ! 719: // ! 720: ! 721: ! 722: // ! 723: // DL_CONNECT_REQ, M_PROTO type ! 724: // ! 725: ! 726: typedef struct { ! 727: unsigned long dl_primitive; // DL_CONNECT_REQ ! 728: unsigned long dl_dest_addr_length; // len. of dlsap addr ! 729: unsigned long dl_dest_addr_offset; // offset ! 730: unsigned long dl_qos_length; // len. of QOS parm val ! 731: unsigned long dl_qos_offset; // offset ! 732: unsigned long dl_growth; // set to zero ! 733: } dl_connect_req_t; ! 734: ! 735: // ! 736: // DL_CONNECT_IND, M_PROTO type ! 737: // ! 738: ! 739: typedef struct { ! 740: unsigned long dl_primitive; // DL_CONNECT_IND ! 741: unsigned long dl_correlation; // provider's correlation token ! 742: unsigned long dl_called_addr_length; // length of called address ! 743: unsigned long dl_called_addr_offset; // offset from beginning of block ! 744: unsigned long dl_calling_addr_length; // length of calling address ! 745: unsigned long dl_calling_addr_offset; // offset from beginning of block ! 746: unsigned long dl_qos_length; // length of qos structure ! 747: unsigned long dl_qos_offset; // offset from beginning of block ! 748: unsigned long dl_growth; // set to zero ! 749: } dl_connect_ind_t; ! 750: ! 751: // ! 752: // DL_CONNECT_RES, M_PROTO type ! 753: // ! 754: ! 755: typedef struct { ! 756: unsigned long dl_primitive; // DL_CONNECT_RES ! 757: unsigned long dl_correlation; // provider's correlation token ! 758: unsigned long dl_resp_token; // token associated with responding stream ! 759: unsigned long dl_qos_length; // length of qos structure ! 760: unsigned long dl_qos_offset; // offset from beginning of block ! 761: unsigned long dl_growth; // set to zero ! 762: } dl_connect_res_t; ! 763: ! 764: // ! 765: // DL_CONNECT_CON, M_PROTO type ! 766: // ! 767: ! 768: typedef struct { ! 769: unsigned long dl_primitive; // DL_CONNECT_CON ! 770: unsigned long dl_resp_addr_length; // length of responder's address ! 771: unsigned long dl_resp_addr_offset; // offset from beginning of block ! 772: unsigned long dl_qos_length; // length of qos structure ! 773: unsigned long dl_qos_offset; // offset from beginning of block ! 774: unsigned long dl_growth; // set to zero ! 775: } dl_connect_con_t; ! 776: ! 777: // ! 778: // DL_TOKEN_REQ, M_PCPROTO type ! 779: // ! 780: ! 781: typedef struct { ! 782: unsigned long dl_primitive; // DL_TOKEN_REQ ! 783: } dl_token_req_t; ! 784: ! 785: // ! 786: // DL_TOKEN_ACK, M_PCPROTO type ! 787: // ! 788: ! 789: typedef struct { ! 790: unsigned long dl_primitive; // DL_TOKEN_ACK ! 791: unsigned long dl_token; // Connection response token ! 792: // associated with the stream ! 793: } dl_token_ack_t; ! 794: ! 795: // ! 796: // DL_DISCONNECT_REQ, M_PROTO type ! 797: // ! 798: ! 799: typedef struct { ! 800: unsigned long dl_primitive; // DL_DISCONNECT_REQ ! 801: unsigned long dl_reason; // normal, abnormal, perm. or transient ! 802: unsigned long dl_correlation; // association with connect_ind ! 803: } dl_disconnect_req_t; ! 804: ! 805: // ! 806: // DL_DISCONNECT_IND, M_PROTO type ! 807: // ! 808: ! 809: typedef struct { ! 810: unsigned long dl_primitive; // DL_DISCONNECT_IND ! 811: unsigned long dl_originator; // USER or PROVIDER ! 812: unsigned long dl_reason; // permanent or transient ! 813: unsigned long dl_correlation; // association with connect_ind ! 814: } dl_disconnect_ind_t; ! 815: ! 816: // ! 817: // DL_RESET_REQ, M_PROTO type ! 818: // ! 819: ! 820: typedef struct { ! 821: unsigned long dl_primitive; // DL_RESET_REQ ! 822: } dl_reset_req_t; ! 823: ! 824: // ! 825: // DL_RESET_IND, M_PROTO type ! 826: // ! 827: ! 828: typedef struct { ! 829: unsigned long dl_primitive; // DL_RESET_IND ! 830: unsigned long dl_originator; // Provider or User ! 831: unsigned long dl_reason; // flow control, link error or resynch ! 832: } dl_reset_ind_t; ! 833: ! 834: // ! 835: // DL_RESET_RES, M_PROTO type ! 836: // ! 837: ! 838: typedef struct { ! 839: unsigned long dl_primitive; // DL_RESET_RES ! 840: } dl_reset_res_t; ! 841: ! 842: // ! 843: // DL_RESET_CON, M_PROTO type ! 844: // ! 845: ! 846: typedef struct { ! 847: unsigned long dl_primitive; // DL_RESET_CON ! 848: } dl_reset_con_t; ! 849: ! 850: // ! 851: // CONNECTIONLESS SERVICE PRIMITIVES ! 852: // ! 853: ! 854: ! 855: // ! 856: // DL_UNITDATA_REQ, M_PROTO type, with M_DATA block(s) ! 857: // ! 858: ! 859: typedef struct { ! 860: unsigned long dl_primitive; // DL_UNITDATA_REQ ! 861: unsigned long dl_dest_addr_length; // DLSAP length of dest. user ! 862: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 863: dl_priority_t dl_priority; // priority value ! 864: } dl_unitdata_req_t; ! 865: ! 866: // ! 867: // DL_UNITDATA_IND, M_PROTO type, with M_DATA block(s) ! 868: // ! 869: ! 870: typedef struct { ! 871: unsigned long dl_primitive; // DL_UNITDATA_IND ! 872: unsigned long dl_dest_addr_length; // DLSAP length of dest. user ! 873: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 874: unsigned long dl_src_addr_length; // DLSAP addr length of sending user ! 875: unsigned long dl_src_addr_offset; // offset from beg. of block ! 876: unsigned long dl_group_address; // set to one if multicast/broadcast ! 877: } dl_unitdata_ind_t; ! 878: ! 879: // ! 880: // DL_UDERROR_IND, M_PROTO type ! 881: // (or M_PCPROTO type if LLI-based provider) ! 882: // ! 883: ! 884: typedef struct { ! 885: unsigned long dl_primitive; // DL_UDERROR_IND ! 886: unsigned long dl_dest_addr_length; // Destination DLSAP ! 887: unsigned long dl_dest_addr_offset; // Offset from beg. of block ! 888: unsigned long dl_unix_errno; // unix system error code ! 889: unsigned long dl_errno; // DLPI error code ! 890: } dl_uderror_ind_t; ! 891: ! 892: // ! 893: // DL_UDQOS_REQ, M_PROTO type ! 894: // ! 895: ! 896: typedef struct { ! 897: unsigned long dl_primitive; // DL_UDQOS_REQ ! 898: unsigned long dl_qos_length; // length in bytes of requested qos ! 899: unsigned long dl_qos_offset; // offset from beg. of block ! 900: } dl_udqos_req_t; ! 901: ! 902: // ! 903: // Primitives to handle XID and TEST operations ! 904: // ! 905: ! 906: ! 907: // ! 908: // DL_TEST_REQ, M_PROTO type ! 909: // ! 910: ! 911: typedef struct { ! 912: unsigned long dl_primitive; // DL_TEST_REQ ! 913: unsigned long dl_flag; // poll/final ! 914: unsigned long dl_dest_addr_length; // DLSAP length of dest. user ! 915: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 916: } dl_test_req_t; ! 917: ! 918: // ! 919: // DL_TEST_IND, M_PROTO type ! 920: // ! 921: ! 922: typedef struct { ! 923: unsigned long dl_primitive; // DL_TEST_IND ! 924: unsigned long dl_flag; // poll/final ! 925: unsigned long dl_dest_addr_length; // dlsap length of dest. user ! 926: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 927: unsigned long dl_src_addr_length; // dlsap length of source user ! 928: unsigned long dl_src_addr_offset; // offset from beg. of block ! 929: } dl_test_ind_t; ! 930: ! 931: // ! 932: // DL_TEST_RES, M_PROTO type ! 933: // ! 934: ! 935: typedef struct { ! 936: unsigned long dl_primitive; // DL_TEST_RES ! 937: unsigned long dl_flag; // poll/final ! 938: unsigned long dl_dest_addr_length; // dlsap length of dest. user ! 939: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 940: } dl_test_res_t; ! 941: ! 942: // ! 943: // DL_TEST_CON, M_PROTO type ! 944: // ! 945: ! 946: typedef struct { ! 947: unsigned long dl_primitive; // DL_TEST_CON ! 948: unsigned long dl_flag; // poll/final ! 949: unsigned long dl_dest_addr_length; // dlsap length of dest. user ! 950: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 951: unsigned long dl_src_addr_length; // dlsap length of source user ! 952: unsigned long dl_src_addr_offset; // offset from beg. of block ! 953: } dl_test_con_t; ! 954: ! 955: // ! 956: // DL_XID_REQ, M_PROTO type ! 957: // ! 958: ! 959: typedef struct { ! 960: unsigned long dl_primitive; // DL_XID_REQ ! 961: unsigned long dl_flag; // poll/final ! 962: unsigned long dl_dest_addr_length; // dlsap length of dest. user ! 963: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 964: } dl_xid_req_t; ! 965: ! 966: // ! 967: // DL_XID_IND, M_PROTO type ! 968: // ! 969: ! 970: typedef struct { ! 971: unsigned long dl_primitive; // DL_XID_IND ! 972: unsigned long dl_flag; // poll/final ! 973: unsigned long dl_dest_addr_length; // dlsap length of dest. user ! 974: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 975: unsigned long dl_src_addr_length; // dlsap length of source user ! 976: unsigned long dl_src_addr_offset; // offset from beg. of block ! 977: } dl_xid_ind_t; ! 978: ! 979: // ! 980: // DL_XID_RES, M_PROTO type ! 981: // ! 982: ! 983: typedef struct { ! 984: unsigned long dl_primitive; // DL_XID_RES ! 985: unsigned long dl_flag; // poll/final ! 986: unsigned long dl_dest_addr_length; // dlsap length of dest. user ! 987: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 988: } dl_xid_res_t; ! 989: ! 990: // ! 991: // DL_XID_CON, M_PROTO type ! 992: // ! 993: ! 994: typedef struct { ! 995: unsigned long dl_primitive; // DL_XID_CON ! 996: unsigned long dl_flag; // poll/final ! 997: unsigned long dl_dest_addr_length; // dlsap length of dest. user ! 998: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 999: unsigned long dl_src_addr_length; // dlsap length of source user ! 1000: unsigned long dl_src_addr_offset; // offset from beg. of block ! 1001: } dl_xid_con_t; ! 1002: ! 1003: // ! 1004: // ACKNOWLEDGED CONNECTIONLESS SERVICE PRIMITIVES ! 1005: // ! 1006: ! 1007: ! 1008: // ! 1009: // DL_DATA_ACK_REQ, M_PROTO type ! 1010: // ! 1011: ! 1012: typedef struct { ! 1013: unsigned long dl_primitive; // DL_DATA_ACK_REQ ! 1014: unsigned long dl_correlation; // User's correlation token ! 1015: unsigned long dl_dest_addr_length; // length of destination addr ! 1016: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 1017: unsigned long dl_src_addr_length; // length of source address ! 1018: unsigned long dl_src_addr_offset; // offset from beg. of block ! 1019: unsigned long dl_priority; // priority ! 1020: unsigned long dl_service_class; // DL_RQST_RSP or DL_RQST_NORSP ! 1021: } dl_data_ack_req_t; ! 1022: ! 1023: // ! 1024: // DL_DATA_ACK_IND, M_PROTO type ! 1025: // ! 1026: ! 1027: typedef struct { ! 1028: unsigned long dl_primitive; // DL_DATA_ACK_IND ! 1029: unsigned long dl_dest_addr_length; // length of destination addr ! 1030: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 1031: unsigned long dl_src_addr_length; // length of source address ! 1032: unsigned long dl_src_addr_offset; // offset from beg. of block ! 1033: unsigned long dl_priority; // priority for data unit transm. ! 1034: unsigned long dl_service_class; // DL_RQST_RSP or DL_RQST_NORSP ! 1035: } dl_data_ack_ind_t; ! 1036: ! 1037: // ! 1038: // DL_DATA_ACK_STATUS_IND, M_PROTO type ! 1039: // ! 1040: ! 1041: typedef struct { ! 1042: unsigned long dl_primitive; // DL_DATA_ACK_STATUS_IND ! 1043: unsigned long dl_correlation; // User's correlation token ! 1044: unsigned long dl_status; // success or failure of previous req ! 1045: } dl_data_ack_status_ind_t; ! 1046: ! 1047: // ! 1048: // DL_REPLY_REQ, M_PROTO type ! 1049: // ! 1050: ! 1051: typedef struct { ! 1052: unsigned long dl_primitive; // DL_REPLY_REQ ! 1053: unsigned long dl_correlation; // User's correlation token ! 1054: unsigned long dl_dest_addr_length; // length of destination addr ! 1055: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 1056: unsigned long dl_src_addr_length; // source address length ! 1057: unsigned long dl_src_addr_offset; // offset from beg. of block ! 1058: unsigned long dl_priority; // priority for data unit transm. ! 1059: unsigned long dl_service_class; ! 1060: } dl_reply_req_t; ! 1061: ! 1062: // ! 1063: // DL_REPLY_IND, M_PROTO type ! 1064: // ! 1065: ! 1066: typedef struct { ! 1067: unsigned long dl_primitive; // DL_REPLY_IND ! 1068: unsigned long dl_dest_addr_length; // length of destination addr ! 1069: unsigned long dl_dest_addr_offset; // offset from beg. of block ! 1070: unsigned long dl_src_addr_length; // source address length ! 1071: unsigned long dl_src_addr_offset; // offset from beg. of block ! 1072: unsigned long dl_priority; // priority for data unit transm. ! 1073: unsigned long dl_service_class; // DL_RQST_RSP or DL_RQST_NORSP ! 1074: } dl_reply_ind_t; ! 1075: ! 1076: // ! 1077: // DL_REPLY_STATUS_IND, M_PROTO type ! 1078: // ! 1079: ! 1080: typedef struct { ! 1081: unsigned long dl_primitive; // DL_REPLY_STATUS_IND ! 1082: unsigned long dl_correlation; // User's correlation token ! 1083: unsigned long dl_status; // success or failure of previous req ! 1084: } dl_reply_status_ind_t; ! 1085: ! 1086: // ! 1087: // DL_REPLY_UPDATE_REQ, M_PROTO type ! 1088: // ! 1089: ! 1090: typedef struct { ! 1091: unsigned long dl_primitive; // DL_REPLY_UPDATE_REQ ! 1092: unsigned long dl_correlation; // User's correlation token ! 1093: unsigned long dl_src_addr_length; // source address length ! 1094: unsigned long dl_src_addr_offset; // offset from beg. of block ! 1095: } dl_reply_update_req_t; ! 1096: ! 1097: // ! 1098: // DL_REPLY_UPDATE_STATUS_IND, M_PROTO type ! 1099: // ! 1100: ! 1101: typedef struct { ! 1102: unsigned long dl_primitive; // DL_REPLY_UPDATE_STATUS_IND ! 1103: unsigned long dl_correlation; // User's correlation token ! 1104: unsigned long dl_status; // success or failure of previous req ! 1105: } dl_reply_update_status_ind_t; ! 1106: ! 1107: // ! 1108: // Performance optimization ! 1109: // ! 1110: ! 1111: typedef struct { ! 1112: ulong dl_primitive; /* DL_SHOULD_PUT_REQ */ ! 1113: ulong context; /* context to pass in should_put */ ! 1114: int (*should_put) ( /* this is the function to call to */ ! 1115: ulong, /* see if a packet should be passed */ ! 1116: char *, /* upstream */ ! 1117: int, /* Arguments are */ ! 1118: char *, /* context, header, headerlen, */ ! 1119: int, /* data, datalen, broadcast flag */ ! 1120: BOOLEAN); ! 1121: } dl_shouldput_t; ! 1122: ! 1123: // ! 1124: // low level adapter info ! 1125: // ! 1126: ! 1127: typedef struct { ! 1128: ulong dl_primitive; /* DL_ADAPTER_INFO_REQ */ ! 1129: } dl_adapter_info_req; ! 1130: ! 1131: typedef struct { ! 1132: ulong dl_primitive; /* DL_ADAPTER_INFO_ACK */ ! 1133: ulong link_speed; /* kbits/second */ ! 1134: ulong receive_buffer_size; /* bytes */ ! 1135: } dl_adapter_info_ack; ! 1136: ! 1137: ! 1138: union DL_primitives { ! 1139: unsigned long dl_primitive; ! 1140: dl_info_req_t info_req; ! 1141: dl_info_ack_t info_ack; ! 1142: dl_attach_req_t attach_req; ! 1143: dl_detach_req_t detach_req; ! 1144: dl_bind_req_t bind_req; ! 1145: dl_bind_ack_t bind_ack; ! 1146: dl_unbind_req_t unbind_req; ! 1147: dl_subs_bind_req_t subs_bind_req; ! 1148: dl_subs_bind_ack_t subs_bind_ack; ! 1149: dl_subs_unbind_req_t subs_unbind_req; ! 1150: dl_ok_ack_t ok_ack; ! 1151: dl_error_ack_t error_ack; ! 1152: dl_connect_req_t connect_req; ! 1153: dl_connect_ind_t connect_ind; ! 1154: dl_connect_res_t connect_res; ! 1155: dl_connect_con_t connect_con; ! 1156: dl_token_req_t token_req; ! 1157: dl_token_ack_t token_ack; ! 1158: dl_disconnect_req_t disconnect_req; ! 1159: dl_disconnect_ind_t disconnect_ind; ! 1160: dl_reset_req_t reset_req; ! 1161: dl_reset_ind_t reset_ind; ! 1162: dl_reset_res_t reset_res; ! 1163: dl_reset_con_t reset_con; ! 1164: dl_unitdata_req_t unitdata_req; ! 1165: dl_unitdata_ind_t unitdata_ind; ! 1166: dl_uderror_ind_t uderror_ind; ! 1167: dl_udqos_req_t udqos_req; ! 1168: dl_enabmulti_req_t enabmulti_req; ! 1169: dl_disabmulti_req_t disabmulti_req; ! 1170: dl_promiscon_req_t promiscon_req; ! 1171: dl_promiscoff_req_t promiscoff_req; ! 1172: dl_phys_addr_req_t physaddr_req; ! 1173: dl_phys_addr_ack_t physaddr_ack; ! 1174: dl_set_phys_addr_req_t set_physaddr_req; ! 1175: dl_get_statistics_req_t get_statistics_req; ! 1176: dl_get_statistics_ack_t get_statistics_ack; ! 1177: dl_test_req_t test_req; ! 1178: dl_test_ind_t test_ind; ! 1179: dl_test_res_t test_res; ! 1180: dl_test_con_t test_con; ! 1181: dl_xid_req_t xid_req; ! 1182: dl_xid_ind_t xid_ind; ! 1183: dl_xid_res_t xid_res; ! 1184: dl_xid_con_t xid_con; ! 1185: dl_data_ack_req_t data_ack_req; ! 1186: dl_data_ack_ind_t data_ack_ind; ! 1187: dl_data_ack_status_ind_t data_ack_status_ind; ! 1188: dl_reply_req_t reply_req; ! 1189: dl_reply_ind_t reply_ind; ! 1190: dl_reply_status_ind_t reply_status_ind; ! 1191: dl_reply_update_req_t reply_update_req; ! 1192: dl_reply_update_status_ind_t reply_update_status_ind; ! 1193: }; ! 1194: ! 1195: #define DL_INFO_REQ_SIZE sizeof(dl_info_req_t) ! 1196: #define DL_INFO_ACK_SIZE sizeof(dl_info_ack_t) ! 1197: #define DL_ATTACH_REQ_SIZE sizeof(dl_attach_req_t) ! 1198: #define DL_DETACH_REQ_SIZE sizeof(dl_detach_req_t) ! 1199: #define DL_BIND_REQ_SIZE sizeof(dl_bind_req_t) ! 1200: #define DL_BIND_ACK_SIZE sizeof(dl_bind_ack_t) ! 1201: #define DL_UNBIND_REQ_SIZE sizeof(dl_unbind_req_t) ! 1202: #define DL_SUBS_BIND_REQ_SIZE sizeof(dl_subs_bind_req_t) ! 1203: #define DL_SUBS_BIND_ACK_SIZE sizeof(dl_subs_bind_ack_t) ! 1204: #define DL_SUBS_UNBIND_REQ_SIZE sizeof(dl_subs_unbind_req_t) ! 1205: #define DL_OK_ACK_SIZE sizeof(dl_ok_ack_t) ! 1206: #define DL_ERROR_ACK_SIZE sizeof(dl_error_ack_t) ! 1207: #define DL_CONNECT_REQ_SIZE sizeof(dl_connect_req_t) ! 1208: #define DL_CONNECT_IND_SIZE sizeof(dl_connect_ind_t) ! 1209: #define DL_CONNECT_RES_SIZE sizeof(dl_connect_res_t) ! 1210: #define DL_CONNECT_CON_SIZE sizeof(dl_connect_con_t) ! 1211: #define DL_TOKEN_REQ_SIZE sizeof(dl_token_req_t) ! 1212: #define DL_TOKEN_ACK_SIZE sizeof(dl_token_ack_t) ! 1213: #define DL_DISCONNECT_REQ_SIZE sizeof(dl_disconnect_req_t) ! 1214: #define DL_DISCONNECT_IND_SIZE sizeof(dl_disconnect_ind_t) ! 1215: #define DL_RESET_REQ_SIZE sizeof(dl_reset_req_t) ! 1216: #define DL_RESET_IND_SIZE sizeof(dl_reset_ind_t) ! 1217: #define DL_RESET_RES_SIZE sizeof(dl_reset_res_t) ! 1218: #define DL_RESET_CON_SIZE sizeof(dl_reset_con_t) ! 1219: #define DL_UNITDATA_REQ_SIZE sizeof(dl_unitdata_req_t) ! 1220: #define DL_UNITDATA_IND_SIZE sizeof(dl_unitdata_ind_t) ! 1221: #define DL_UDERROR_IND_SIZE sizeof(dl_uderror_ind_t) ! 1222: #define DL_UDQOS_REQ_SIZE sizeof(dl_udqos_req_t) ! 1223: #define DL_ENABMULTI_REQ_SIZE sizeof(dl_enabmulti_req_t) ! 1224: #define DL_DISABMULTI_REQ_SIZE sizeof(dl_disabmulti_req_t) ! 1225: #define DL_PROMISCON_REQ_SIZE sizeof(dl_promiscon_req_t) ! 1226: #define DL_PROMISCOFF_REQ_SIZE sizeof(dl_promiscoff_req_t) ! 1227: #define DL_PHYS_ADDR_REQ_SIZE sizeof(dl_phys_addr_req_t) ! 1228: #define DL_PHYS_ADDR_ACK_SIZE sizeof(dl_phys_addr_ack_t) ! 1229: #define DL_SET_PHYS_ADDR_REQ_SIZE sizeof(dl_set_phys_addr_req_t) ! 1230: #define DL_GET_STATISTICS_REQ_SIZE sizeof(dl_get_statistics_req_t) ! 1231: #define DL_GET_STATISTICS_ACK_SIZE sizeof(dl_get_statistics_ack_t) ! 1232: #define DL_XID_REQ_SIZE sizeof(dl_xid_req_t) ! 1233: #define DL_XID_IND_SIZE sizeof(dl_xid_ind_t) ! 1234: #define DL_XID_RES_SIZE sizeof(dl_xid_res_t) ! 1235: #define DL_XID_CON_SIZE sizeof(dl_xid_con_t) ! 1236: #define DL_TEST_REQ_SIZE sizeof(dl_test_req_t) ! 1237: #define DL_TEST_IND_SIZE sizeof(dl_test_ind_t) ! 1238: #define DL_TEST_RES_SIZE sizeof(dl_test_res_t) ! 1239: #define DL_TEST_CON_SIZE sizeof(dl_test_con_t) ! 1240: #define DL_DATA_ACK_REQ_SIZE sizeof(dl_data_ack_req_t) ! 1241: #define DL_DATA_ACK_IND_SIZE sizeof(dl_data_ack_ind_t) ! 1242: #define DL_DATA_ACK_STATUS_IND_SIZE sizeof(dl_data_ack_status_ind_t) ! 1243: #define DL_REPLY_REQ_SIZE sizeof(dl_reply_req_t) ! 1244: #define DL_REPLY_IND_SIZE sizeof(dl_reply_ind_t) ! 1245: #define DL_REPLY_STATUS_IND_SIZE sizeof(dl_reply_status_ind_t) ! 1246: #define DL_REPLY_UPDATE_REQ_SIZE sizeof(dl_reply_update_req_t) ! 1247: #define DL_REPLY_UPDATE_STATUS_IND_SIZE sizeof(dl_reply_update_status_ind_t) ! 1248: ! 1249: #endif // _SYS_DLPI_H
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.