/*************************************************************************** * DBS: Distributed Benchmark System * Copyright (c) 1995, 1996, 1997 Yukio Murayama * Copyright (c) 1995, 1996, 1997 Nara Institute of Science and Technology * All rights reserved. * * Permission to use, copy, modify and distribute this software and its * documentation is hereby granted, provided only with the following * conditions are satisfied: * * 1. Both the copyright notice and this permission notice appear in * all copies of the software, derivative works or modified versions, * and any portions thereof, and that both notices appear in * supporting documentation. * 2. All advertising materials mentioning features or use of this * software must display the following acknowledgement: * This product includes software developed by Nara Institute of * Science and Technology and its contributors. * 3. Neither the name of Nara Institute of Science and Technology 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 DEVELOPER ``AS IS'' AND NARA * INSTITUTE OF SCIENCE AND TECHNOLOGY DISCLAIMS ANY LIABILITY OF * ANY KIND FOR ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF * THIS SOFTWARE. ALSO, THERE IS NO WARRANTY IMPLIED OR OTHERWISE, * NOR IS SUPPORT PROVIDED. * * Feedback of the results generated from any improvements or * extensions made to this software would be much appreciated. * Any such feedback should be sent to: * * Yukio Murayama * E-mail: * URL: * Address: Graduate School of Information Science, * Nara Institute of Science and Technology, * Takayama 8916-5, Ikoma, Nara, Japan * * Nara Institute of Science and Technology has the rights to * redistribute these changes. ***************************************************************************/ /***************************************************************** * Distributed Benchmark System * RECORD Header File * $Revision: 1.11 $ * $Date: 1997/07/11 00:54:09 $ * $Author: yukio-m $ *****************************************************************/ #include /*#include */ #include /*#define PRUREQUESTS*/ #if !defined(sony_news) && !defined(__linux__) #include #endif #include #include #include #include #include #include #include #ifndef __linux__ #include #include #include /*#define TCPSTATES*/ #include #include /*#define TCPTIMERS*/ #include #include /*#define TANAMES*/ #include #endif /*#include */ #ifdef __linux__ #define TA_INPUT 0 #define TA_OUTPUT 1 #define TA_USER 2 #define TA_RESPOND 3 #define TA_DROP 4 #endif /***** Time Record Structure *****/ struct record_d { struct timeval tv; int packet_no; int packet_size; }; struct record { struct record_d *d; int n; int size; }; struct tcp_trace { struct tcp_debug *d; int n; caddr_t tcp_addr; int size; int memf; int p; }; /***** sendrecv.c *****/ int tcp_send __P((struct dbsd_param * volatile cmd, char *data, struct record *rd, struct record *rd2, struct tcp_trace * volatile rt)); int tcp_recv __P((struct dbsd_param * volatile cmd, char *data, struct record *rd, struct record *rd2, struct tcp_trace * volatile rt)); int udp_send __P((struct dbsd_param * volatile cmd, char *data, struct record *rd)); int udp_recv __P((struct dbsd_param * volatile cmd, char *data, struct record *rd)); /***** tcp_trace.c *****/ void record_tcp_trace __P((struct tcp_trace *rt, struct assosiation *a, int act)); void record_tcp_trace2 __P((struct tcp_trace *rt, struct assosiation *a, int act)); void init_so_debug __P((struct tcp_trace *rt, struct assosiation *a, int act, int flg));