BSD 4_3_Net_2 release
[unix-history] / usr / src / sys / netiso / tp_trace.h
index 21e0c2d..9d0c6b3 100644 (file)
@@ -1,3 +1,38 @@
+/*-
+ * Copyright (c) 1991 The Regents of the University of California.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ * 3. All advertising materials mentioning features or use of this software
+ *    must display the following acknowledgement:
+ *     This product includes software developed by the University of
+ *     California, Berkeley and its contributors.
+ * 4. Neither the name of the University nor the names of its contributors
+ *    may be used to endorse or promote products derived from this software
+ *    without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ *     @(#)tp_trace.h  7.5 (Berkeley) 6/27/91
+ */
+
 /***********************************************************
                Copyright IBM Corporation 1987
 
 /***********************************************************
                Copyright IBM Corporation 1987
 
@@ -29,7 +64,6 @@ SOFTWARE.
  *
  * $Header: tp_trace.h,v 5.1 88/10/12 12:21:51 root Exp $
  * $Source: /usr/argo/sys/netiso/RCS/tp_trace.h,v $
  *
  * $Header: tp_trace.h,v 5.1 88/10/12 12:21:51 root Exp $
  * $Source: /usr/argo/sys/netiso/RCS/tp_trace.h,v $
- *     @(#)tp_trace.h  7.3 (Berkeley) 8/29/89 *
  *
  * 
  * Definitions needed for the protocol trace mechanism.
  *
  * 
  * Definitions needed for the protocol trace mechanism.
@@ -38,7 +72,6 @@ SOFTWARE.
 #ifndef __TP_TRACE__
 #define __TP_TRACE__
 
 #ifndef __TP_TRACE__
 #define __TP_TRACE__
 
-#ifdef TPPT
 
 #define TPPTsendack    1
 #define TPPTgotack     2
 
 #define TPPTsendack    1
 #define TPPTgotack     2
@@ -116,23 +149,12 @@ struct    tp_Trace {
 #define tpt_window tpt_stuff.tpt_Time.tptv_window
 #define tpt_size tpt_stuff.tpt_Time.tptv_size
 
 #define tpt_window tpt_stuff.tpt_Time.tptv_window
 #define tpt_size tpt_stuff.tpt_Time.tptv_size
 
-#define TPTRACEN 300
-int tp_Tracen = 0;
-struct tp_Trace tp_Trace[TPTRACEN];
-
 #endif defined(TP_TRACEFILE)||!defined(KERNEL)
 
 #endif defined(TP_TRACEFILE)||!defined(KERNEL)
 
-extern u_char  tp_traceflags[];
-
-#define IFTRACE(ascii)\
-       if(tp_traceflags[ascii]) {
-/* 
- * for some reason lint complains about tp_param being undefined no
- * matter where or how many times I define it.
- */
 
 
+#ifdef TPPT
 
 
-#define ENDTRACE  }
+#define TPTRACEN 300
 
 #define tptrace(A,B,C,D,E,F) \
        tpTrace((struct tp_pcb *)0,\
 
 #define tptrace(A,B,C,D,E,F) \
        tpTrace((struct tp_pcb *)0,\
@@ -143,19 +165,34 @@ extern u_char     tp_traceflags[];
        (u_int)(A),(u_int)(B),(u_int)(C),(u_int)(D),(u_int)(E),(u_int)(F))
 
 extern void tpTrace();
        (u_int)(A),(u_int)(B),(u_int)(C),(u_int)(D),(u_int)(E),(u_int)(F))
 
 extern void tpTrace();
+extern struct tp_Trace tp_Trace[];
+extern u_char  tp_traceflags[];
+int tp_Tracen = 0;
+
+#define IFTRACE(ascii)\
+       if(tp_traceflags[ascii]) {
+/* 
+ * for some reason lint complains about tp_param being undefined no
+ * matter where or how many times I define it.
+ */
+#define ENDTRACE  }
+
 
 #else  TPPT
 
 /***********************************************
  * NO TPPT TRACE STUFF
  **********************************************/
 
 #else  TPPT
 
 /***********************************************
  * NO TPPT TRACE STUFF
  **********************************************/
+#define TPTRACEN 1
+
+#define tptrace(A,B,C,D,E,F) 0
+#define tptraceTPCB(A,B,C,D,E,F) 0
 
 
-#ifndef STAR
-#define STAR *
-#endif STAR
-#define IFTRACE(ascii)  //*beginning of comment*/STAR
-#define ENDTRACE        STAR/*end of comment*//
+#define IFTRACE(ascii)  if (0) {
+#define ENDTRACE        }
 
 #endif TPPT
 
 
 #endif TPPT
 
+
+
 #endif __TP_TRACE__
 #endif __TP_TRACE__