lqr.h revision 32663
1/*
2 *	    Written by Toshiharu OHNO (tony-o@iij.ad.jp)
3 *
4 *   Copyright (C) 1993, Internet Initiative Japan, Inc. All rights reserverd.
5 *
6 * Redistribution and use in source and binary forms are permitted
7 * provided that the above copyright notice and this paragraph are
8 * duplicated in all such forms and that any documentation,
9 * advertising materials, and other materials related to such
10 * distribution and use acknowledge that the software was developed
11 * by the Internet Initiative Japan.  The name of the
12 * IIJ may not be used to endorse or promote products derived
13 * from this software without specific prior written permission.
14 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
15 * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
16 * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
17 *
18 * $Id: lqr.h,v 1.11 1998/01/11 17:50:42 brian Exp $
19 *
20 *	TODO:
21 */
22
23/*
24 *  Structure of LQR packet defined in RFC1333
25 */
26struct lqrdata {
27  u_int32_t MagicNumber;
28  u_int32_t LastOutLQRs;
29  u_int32_t LastOutPackets;
30  u_int32_t LastOutOctets;
31  u_int32_t PeerInLQRs;
32  u_int32_t PeerInPackets;
33  u_int32_t PeerInDiscards;
34  u_int32_t PeerInErrors;
35  u_int32_t PeerInOctets;
36  u_int32_t PeerOutLQRs;
37  u_int32_t PeerOutPackets;
38  u_int32_t PeerOutOctets;
39};
40
41struct lqrsave {
42  u_int32_t SaveInLQRs;
43  u_int32_t SaveInPackets;
44  u_int32_t SaveInDiscards;
45  u_int32_t SaveInErrors;
46  u_int32_t SaveInOctets;
47};
48
49extern struct lqrdata MyLqrData, HisLqrData;
50extern struct lqrsave HisLqrSave;
51
52/*
53 *  We support LQR and ECHO as LQM method
54 */
55#define	LQM_LQR	  1
56#define	LQM_ECHO  2
57
58extern void LqrDump(const char *, const struct lqrdata *);
59extern void LqrChangeOrder(struct lqrdata *, struct lqrdata *);
60extern void StartLqm(void);
61extern void StopLqr(int);
62extern void StopLqrTimer(void);
63extern void RecvEchoLqr(struct mbuf *);
64extern void LqrInput(struct mbuf *);
65