From owner-freebsd-hackers Sun Jul 6 16:33:22 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id QAA11231 for hackers-outgoing; Sun, 6 Jul 1997 16:33:22 -0700 (PDT) Received: from whistle.com (s205m131.whistle.com [207.76.205.131]) by hub.freebsd.org (8.8.5/8.8.5) with ESMTP id QAA11217 for ; Sun, 6 Jul 1997 16:33:16 -0700 (PDT) Received: (from smap@localhost) by whistle.com (8.7.5/8.6.12) id QAA18474 for ; Sun, 6 Jul 1997 16:32:42 -0700 (PDT) Received: from bubba.whistle.com(207.76.205.7) by whistle.com via smap (V1.3) id sma018472; Sun Jul 6 16:32:28 1997 Received: (from archie@localhost) by bubba.whistle.com (8.8.5/8.6.12) id QAA13618 for freebsd-hackers@freebsd.org; Sun, 6 Jul 1997 16:32:28 -0700 (PDT) From: Archie Cobbs Message-Id: <199707062332.QAA13618@bubba.whistle.com> Subject: VJ compression and MAX_HDR To: freebsd-hackers@freebsd.org Date: Sun, 6 Jul 1997 16:32:28 -0700 (PDT) X-Mailer: ELM [version 2.4ME+ PL31 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk In slcompress.h, MAX_HDR is defined so: #define MAX_HDR MLEN /* XXX 4bsd-ism: should really be 128 */ MLEN is like 108 or something. This means that when Van Jacobson compression is active, any packets sent to us with combined IP and TCP header length greater than MLEN will be dropped, always. This is an admittedly rare case, but my question is, why was this done? What code would break if MAX_HDR is changed back to 128? Searching for "MAX_HDR" in every source file in /usr/src/sys shows that it only appears in slcompress.c and slcompress.h; moreover, the code in if_ppp.c and if_sl.c seems to properly handle uncompressed headers having length greater than MLEN (from a cursory glance). Therefore, may I propose the following patch? Or else someone please elighten me. Thanks, -Archie ___________________________________________________________________________ Archie Cobbs * Whistle Communications, Inc. * http://www.whistle.com Index: slcompress.h =================================================================== RCS file: /cvs/freebsd/src/sys/net/slcompress.h,v retrieving revision 1.9 diff -c -r1.9 slcompress.h *** 1.9 1996/01/30 22:58:03 --- slcompress.h 1997/07/06 23:21:52 *************** *** 42,48 **** #define _NET_SLCOMPRESS_H_ #define MAX_STATES 16 /* must be > 2 and < 256 */ ! #define MAX_HDR MLEN /* XXX 4bsd-ism: should really be 128 */ /* * Compressed packet format: --- 42,48 ---- #define _NET_SLCOMPRESS_H_ #define MAX_STATES 16 /* must be > 2 and < 256 */ ! #define MAX_HDR 128 /* max size of combined IP + TCP headers */ /* * Compressed packet format: