Annotation of Net2/netiso/argo_debug.h, revision 1.1.1.3

1.1       root        1: /*-
                      2:  * Copyright (c) 1991 The Regents of the University of California.
                      3:  * All rights reserved.
                      4:  *
                      5:  * Redistribution and use in source and binary forms, with or without
                      6:  * modification, are permitted provided that the following conditions
                      7:  * are met:
                      8:  * 1. Redistributions of source code must retain the above copyright
                      9:  *    notice, this list of conditions and the following disclaimer.
                     10:  * 2. Redistributions in binary form must reproduce the above copyright
                     11:  *    notice, this list of conditions and the following disclaimer in the
                     12:  *    documentation and/or other materials provided with the distribution.
                     13:  * 3. All advertising materials mentioning features or use of this software
                     14:  *    must display the following acknowledgement:
                     15:  *     This product includes software developed by the University of
                     16:  *     California, Berkeley and its contributors.
                     17:  * 4. Neither the name of the University nor the names of its contributors
                     18:  *    may be used to endorse or promote products derived from this software
                     19:  *    without specific prior written permission.
                     20:  *
                     21:  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
                     22:  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
                     23:  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
                     24:  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
                     25:  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
                     26:  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
                     27:  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
                     28:  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
                     29:  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
                     30:  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
                     31:  * SUCH DAMAGE.
                     32:  *
1.1.1.3 ! root       33:  *     from: @(#)argo_debug.h  7.4 (Berkeley) 5/6/91
        !            34:  *     argo_debug.h,v 1.3 1993/05/20 05:26:42 cgd Exp
1.1       root       35:  */
                     36: 
1.1.1.3 ! root       37: #ifndef _NETISO_ARGO_DEBUG_H_
        !            38: #define _NETISO_ARGO_DEBUG_H_
        !            39: 
1.1       root       40: /*****************************************************************
                     41:                                Copyright IBM Corporation 1987
                     42: 
                     43:                       All Rights Reserved
                     44: 
                     45: Permission to use, copy, modify, and distribute this software and its 
                     46: documentation for any purpose and without fee is hereby granted, 
                     47: provided that the above copyright notice appear in all copies and that
                     48: both that copyright notice and this permission notice appear in 
                     49: supporting documentation, and that the name of IBM not be
                     50: used in advertising or publicity pertaining to distribution of the
                     51: software without specific, written prior permission.  
                     52: 
                     53: IBM DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
                     54: ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
                     55: IBM BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
                     56: ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
                     57: WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
                     58: ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
                     59: SOFTWARE.
                     60: 
                     61: ******************************************************************/
                     62: 
                     63: /*
                     64:  * ARGO Project, Computer Sciences Dept., University of Wisconsin - Madison
                     65:  */
                     66: 
                     67: #define dump_buf(a, b) Dump_buf((caddr_t)(a), (int)(b))
                     68: 
                     69: /***********************************************
                     70:  * Lint stuff
                     71:  **********************************************/
                     72: #if    defined(lint)
                     73: /* 
                     74:  * lint can't handle the flaky vacuous definitions 
                     75:  * of IFDEBUG, ENDDEBUG, etc.
                     76:  */
                     77: #endif defined(lint)
                     78: 
                     79: /***********************************************
                     80:  * DEBUG ON:
                     81:  **********************************************/
                     82: #ifndef ARGO_DEBUG
                     83: #define ARGO_DEBUG
                     84: #endif ARGO_DEBUG
                     85: 
                     86: 
                     87: #ifdef ARGO_DEBUG
                     88: /*
                     89:     #ifndef TPPT
                     90:     #define TPPT
                     91:     #endif TPPT
                     92: 
                     93:     #ifndef TP_PERF_MEAS
                     94:     #define TP_PERF_MEAS
                     95:     #endif TP_PERF_MEAS
                     96: */
                     97: 
                     98: unsigned char  argo_debug[128];
                     99: 
                    100: #define IFDEBUG(ascii) \
                    101:        if(argo_debug[ascii]) { 
                    102: #define ENDDEBUG  ; }
                    103: 
                    104: #else  ARGO_DEBUG
                    105: 
                    106: /***********************************************
                    107:  * DEBUG OFF:
                    108:  **********************************************/
                    109: 
                    110: #ifndef STAR
                    111: #define STAR *
                    112: #endif STAR
                    113: #define IFDEBUG(ascii)  //*beginning of comment*/STAR
                    114: #define ENDDEBUG        STAR/*end of comment*//
                    115: 
                    116: #endif ARGO_DEBUG
                    117: 
                    118: /***********************************************
                    119:  * ASSERT 
                    120:  **********************************************/
                    121: #ifdef ARGO_DEBUG
                    122: 
                    123: #ifndef lint
                    124: #define ASSERT(phrase) \
                    125: if( !(phrase) ) printf("ASSERTION NOT VALID at line %d file %s\n",__LINE__,__FILE__)
                    126: #else lint
                    127: #define ASSERT(phrase) /* phrase */
                    128: #endif lint
                    129: 
                    130: #else ARGO_DEBUG
                    131: 
                    132: #define ASSERT(phrase) /* phrase */
                    133: 
                    134: #endif ARGO_DEBUG
                    135: 
                    136: 
                    137: /***********************************************
                    138:  * CLNP DEBUG OPTIONS
                    139:  **********************************************/
                    140: #define        D_INPUT                 '\1'
                    141: /* clnp input */
                    142: #define        D_OUTPUT                '\2'
                    143: /* clnp output */
                    144: #define        D_ROUTE                 '\3'
                    145: /* clnp routing */
                    146: #define        D_CTLINPUT              '\4'
                    147: /* clnp control input */
                    148: #define        D_CTLOUTPUT             '\5'
                    149: /* clnp control output */
                    150: #define D_OPTIONS              '\6'
                    151: /* clnp options */
                    152: #define        D_IOCTL                 '\7'
                    153: /* iso ioctls */
                    154: #define D_ETHER                        '\10'
                    155: /* clnp over ethernet */
                    156: #define D_TOKEN                        '\11'
                    157: /* clnp over token ring */
                    158: #define D_ADCOM                        '\12'
                    159: /* clnp over the adcom */
                    160: #define D_ISO                  '\13'   
                    161: /* iso address family */
                    162: #define        D_FORWARD               '\14'
                    163: /* clnp forwarding */
                    164: #define        D_DUMPOUT               '\15'
                    165: /* dump clnp outgoing packets */
                    166: #define        D_DUMPIN                '\16'   
                    167: /* dump clnp input packets */
                    168: #define D_DISCARD              '\17'   
                    169: /* debug clnp packet discard/er function */
                    170: #define D_FRAG                 '\20'   
                    171: /* clnp fragmentation */
                    172: #define        D_REASS                 '\21'   
                    173: /* clnp reassembly */
                    174: 
                    175: char *clnp_iso_addrp();
                    176: 
                    177: /***********************************************
                    178:  * ESIS DEBUG OPTIONS
                    179:  **********************************************/
                    180: #define        D_ESISOUTPUT    '\30'
                    181: #define        D_ESISINPUT             '\31'
                    182: #define D_SNPA                 '\32'
                    183: 
                    184: /***********************************************
                    185:  * ISIS DEBUG OPTIONS
                    186:  **********************************************/
                    187: #define D_ISISOUTPUT   '\40'
                    188: #define D_ISISINPUT            '\41'
                    189: 
                    190: /***********************************************
                    191:  * EON DEBUG OPTION
                    192:  **********************************************/
                    193: #define        D_EON                   '\57'
                    194: 
                    195: /***********************************************
                    196:  * CONS DEBUG OPTIONS
                    197:  **********************************************/
                    198: 
                    199: #define D_ECNWORK              '\60'
                    200: #define D_ECNOUT               '\61'
                    201: #define D_ECNFIN               '\62'
                    202: #define D_ECNDWN               '\63'
                    203: #define D_ECNUTIL              '\64'
                    204: 
                    205: #define D_INCOMING             '\70'
                    206: #define D_CDATA                        '\71'
                    207: #define D_CFIND                        '\72'
                    208: #define D_CDUMP_REQ            '\73'
                    209: #define D_CADDR                        '\74'
                    210: #define D_CCONS                        '\75'
                    211: #define D_CCONN                        '\76'
                    212: 
                    213: 
                    214: /***********************************************
                    215:  * TP DEBUG OPTIONS
                    216:  **********************************************/
                    217: 
                    218: #define D_SETPARAMS            '\137'
                    219: #define D_RTT                  '\140'
                    220: 
                    221: #define D_ACKRECV              '\141'
                    222: #define D_ACKSEND              '\142'
                    223: #define D_CONN                         '\143'
                    224: #define D_CREDIT               '\144'
                    225: #define D_DATA                         '\145'
                    226: #define D_DRIVER               '\146'
                    227: 
                    228: #define D_EMIT                         '\147'
                    229: #define D_ERROR_EMIT   '\150'
                    230: #define D_TPINPUT              '\151'
                    231: #define D_INDICATION   '\152'
                    232: #define D_CHKSUM               '\153'
                    233: 
                    234: #define D_RENEG                '\154'
                    235: #define D_PERF_MEAS    '\155'
                    236: #define D_MBUF_MEAS    '\156'
                    237: #define D_RTC                  '\157'
                    238: #define D_SB                   '\160'
                    239: 
                    240: #define D_DISASTER_CHECK '\161'
                    241: #define D_REQUEST              '\162'
                    242: #define D_STASH                '\163'
                    243: #define D_NEWSOCK              '\164'
                    244: #define D_TIMER                '\165'
                    245: 
                    246: #define D_TPIOCTL              '\166'
                    247: #define D_SIZE_CHECK   '\167'
                    248: #define D_2ER                  '\170'
                    249: #define D_DISASTER_CHECK_W '\171'
                    250: 
                    251: #define D_XPD                  '\172'
                    252: #define D_SYSCALL              '\173'
                    253: #define D_DROP                         '\174'
                    254: #define D_ZDREF                '\175'
                    255: #define D_TPISO                        '\176'
                    256: #define D_QUENCH               '\177'
                    257: 
                    258: void dump_mbuf();
                    259: 
                    260: /***********************************************
                    261:  * New mbuf types for debugging w/ netstat -m
                    262:  * This messes up 4.4 malloc for now. need bigger
                    263:  * mbtypes array for now.
                    264:  **********************************************/
                    265: #ifdef notdef
                    266: 
                    267: #define        TPMT_DATA       0x21
                    268: #define        TPMT_RCVRTC     0x42
                    269: #define        TPMT_SNDRTC     0x41
                    270: #define        TPMT_TPHDR      0x22
                    271: #define        TPMT_IPHDR      0x32
                    272: #define        TPMT_SONAME     0x28
                    273: #define        TPMT_EOT        0x40
                    274: #define        TPMT_XPD        0x44
                    275: #define        TPMT_PCB        0x23
                    276: #define        TPMT_PERF       0x45
                    277: 
                    278: #else ARGO_DEBUG
                    279: 
                    280: #define        TPMT_DATA       MT_DATA
                    281: #define        TPMT_RCVRTC     MT_DATA
                    282: #define        TPMT_SNDRTC     MT_DATA
                    283: #define        TPMT_IPHDR      MT_HEADER
                    284: #define        TPMT_TPHDR      MT_HEADER
                    285: #define        TPMT_SONAME     MT_SONAME
                    286: /* MT_EOT and MT_XPD are defined in tp_param.h */
                    287: #define        TPMT_XPD        MT_OOBDATA
                    288: #define        TPMT_PCB        MT_PCB
                    289: #define        TPMT_PERF       MT_PCB
                    290: 
                    291: #endif ARGO_DEBUG
                    292: 
1.1.1.3 ! root      293: #endif /* !_NETISO_ARGO_DEBUG_H_ */

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.