|
|
1.1 ! root 1: /*********************************************************** ! 2: Copyright IBM Corporation 1987 ! 3: ! 4: All Rights Reserved ! 5: ! 6: Permission to use, copy, modify, and distribute this software and its ! 7: documentation for any purpose and without fee is hereby granted, ! 8: provided that the above copyright notice appear in all copies and that ! 9: both that copyright notice and this permission notice appear in ! 10: supporting documentation, and that the name of IBM not be ! 11: used in advertising or publicity pertaining to distribution of the ! 12: software without specific, written prior permission. ! 13: ! 14: IBM DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ! 15: ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL ! 16: IBM BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ! 17: ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, ! 18: WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ! 19: ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS ! 20: SOFTWARE. ! 21: ! 22: ******************************************************************/ ! 23: ! 24: /* ! 25: * ARGO Project, Computer Sciences Dept., University of Wisconsin - Madison ! 26: */ ! 27: /* ! 28: * $Header: esis.h,v 4.7 88/09/15 11:24:18 hagens Exp $ ! 29: * $Source: /usr/argo/sys/netiso/RCS/esis.h,v $ ! 30: * @(#)esis.h 7.3 (Berkeley) 8/29/89 * ! 31: */ ! 32: ! 33: #ifndef BYTE_ORDER ! 34: /* ! 35: * Definitions for byte order, ! 36: * according to byte significance from low address to high. ! 37: */ ! 38: #define LITTLE_ENDIAN 1234 /* least-significant byte first (vax) */ ! 39: #define BIG_ENDIAN 4321 /* most-significant byte first (IBM, net) */ ! 40: #define PDP_ENDIAN 3412 /* LSB first in word, MSW first in long (pdp) */ ! 41: ! 42: #ifdef vax ! 43: #define BYTE_ORDER LITTLE_ENDIAN ! 44: #else ! 45: #define BYTE_ORDER BIG_ENDIAN /* mc68000, tahoe, most others */ ! 46: #endif ! 47: #endif BYTE_ORDER ! 48: ! 49: #define SNPAC_AGE 60 /* seconds */ ! 50: #define ESIS_CONFIG 60 /* seconds */ ! 51: #define ESIS_HT (ESIS_CONFIG * 2) ! 52: ! 53: /* ! 54: * Fixed part of an ESIS header ! 55: */ ! 56: struct esis_fixed { ! 57: u_char esis_proto_id; /* network layer protocol identifier */ ! 58: u_char esis_hdr_len; /* length indicator (octets) */ ! 59: u_char esis_vers; /* version/protocol identifier extension */ ! 60: u_char esis_res1; /* reserved */ ! 61: u_char esis_type; /* type code */ ! 62: /* technically, type should be &='d 0x1f */ ! 63: #define ESIS_ESH 0x02 /* End System Hello */ ! 64: #define ESIS_ISH 0x04 /* Intermediate System Hello */ ! 65: #define ESIS_RD 0x06 /* Redirect */ ! 66: u_char esis_ht_msb; /* holding time (seconds) high byte */ ! 67: u_char esis_ht_lsb; /* holding time (seconds) low byte */ ! 68: u_char esis_cksum_msb; /* checksum high byte */ ! 69: u_char esis_cksum_lsb; /* checksum low byte */ ! 70: }; ! 71: /* ! 72: * Values for ESIS datagram options ! 73: */ ! 74: #define ESISOVAL_NETMASK 0xe1 /* address mask option, RD PDU only */ ! 75: #define ESISOVAL_SNPAMASK 0xe2 /* snpa mask option, RD PDU only */ ! 76: #define ESISOVAL_ESCT 0xc6 /* end system conf. timer, ISH PDU only */ ! 77: ! 78: ! 79: #define ESIS_CKSUM_OFF 0x07 ! 80: #define ESIS_CKSUM_REQUIRED(pdu)\ ! 81: ((pdu->esis_cksum_msb != 0) || (pdu->esis_cksum_lsb != 0)) ! 82: ! 83: #define ESIS_VERSION 1 ! 84: ! 85: struct esis_stat { ! 86: u_short es_nomem; /* insufficient memory to send hello */ ! 87: u_short es_badcsum; /* incorrect checksum */ ! 88: u_short es_badvers; /* incorrect version number */ ! 89: u_short es_badtype; /* unknown pdu type field */ ! 90: u_short es_toosmall; /* packet too small */ ! 91: u_short es_eshsent; /* ESH sent */ ! 92: u_short es_eshrcvd; /* ESH rcvd */ ! 93: u_short es_ishsent; /* ISH sent */ ! 94: u_short es_ishrcvd; /* ISH rcvd */ ! 95: u_short es_rdsent; /* RD sent */ ! 96: u_short es_rdrcvd; /* RD rcvd */ ! 97: }; ! 98: ! 99: #ifdef KERNEL ! 100: struct esis_stat esis_stat; ! 101: #endif KERNEL
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.