Reduce MAX_M[RT]U back to 2048. Even on a null-modem
ppp link, we gain nothing with a larger mtu. Suggested by: joerg Fix pred1 buffer size (must be == MAX_MTU)
This commit is contained in:
parent
5c4722ca2f
commit
0d8fb00071
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=26341
@ -15,7 +15,7 @@
|
||||
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
|
||||
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
|
||||
*
|
||||
* $Id: hdlc.h,v 1.6 1997/02/22 16:10:17 peter Exp $
|
||||
* $Id: hdlc.h,v 1.7 1997/06/01 01:13:02 brian Exp $
|
||||
*
|
||||
* TODO:
|
||||
*/
|
||||
@ -39,11 +39,11 @@
|
||||
#define GOODFCS 0xf0b8 /* Good FCS value */
|
||||
|
||||
#define DEF_MRU 1500
|
||||
#define MAX_MRU 16384
|
||||
#define MAX_MRU 2048
|
||||
#define MIN_MRU 296
|
||||
|
||||
#define DEF_MTU 0 /* whatever peer says */
|
||||
#define MAX_MTU 16384
|
||||
#define MAX_MTU 2048
|
||||
#define MIN_MTU 296
|
||||
|
||||
/*
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
/*
|
||||
*
|
||||
* $Id: pred.c,v 1.9 1997/02/22 16:10:47 peter Exp $
|
||||
* $Id: pred.c,v 1.10 1997/05/10 01:22:18 brian Exp $
|
||||
*
|
||||
* pred.c -- Test program for Dave Rand's rendition of the
|
||||
* predictor algorithm
|
||||
@ -94,8 +94,6 @@ int len;
|
||||
return(dest - orgdest);
|
||||
}
|
||||
|
||||
#define SIZ1 2048
|
||||
|
||||
void
|
||||
Pred1Init(direction)
|
||||
int direction;
|
||||
@ -116,7 +114,7 @@ Pred1Output(int pri, u_short proto, struct mbuf *bp)
|
||||
struct mbuf *mwp;
|
||||
u_char *cp, *wp, *hp;
|
||||
int orglen, len;
|
||||
u_char bufp[SIZ1];
|
||||
u_char bufp[MAX_MTU];
|
||||
u_short fcs;
|
||||
|
||||
orglen = plength(bp) + 2; /* add count of proto */
|
||||
@ -162,7 +160,7 @@ struct mbuf *bp;
|
||||
u_char *bufp;
|
||||
u_short fcs, proto;
|
||||
|
||||
wp = mballoc(SIZ1, MB_IPIN);
|
||||
wp = mballoc(MAX_MTU, MB_IPIN);
|
||||
cp = MBUF_CTOP(bp);
|
||||
olen = plength(bp);
|
||||
pp = bufp = MBUF_CTOP(wp);
|
||||
|
Loading…
Reference in New Issue
Block a user