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

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

unix.superglobalmegacorp.com

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