From: Charles Hedrick (hedrick@geneva.rutgers.edu)
Date: 08/02/93


From: hedrick@geneva.rutgers.edu (Charles Hedrick)
Subject: Re: Simple Q's on SLIP, DIP and a bad trip.
Date: 2 Aug 1993 08:34:56 GMT

Ken.Wallace@f608.n257.z2.fidonet.org (Ken Wallace) writes:

>CH> The kernel defaults to CSLIP. To disable compression, go
>CH> into ..net/inet/slip.c, and remove the call to slhc_compress
>CH> in sl_encaps. That is, remove the two lines marked below
>CH> with >> . This is an FAQ. Could it be put in some FAQ document?

>Better still, edit /usr/src/linux/net/inet/CONFIG and comment out
>the define for compressed slip;

>SLIP_OPTS = -DSL_DUMP -DSL_COMPRESSED
> ^
> insert #

This is sort of embarassing. While your suggestion should work, it
doesn't. It was too late at night when I told Linus where to put the
conditional. If you disable SL_COMPRESSED, you'll keep your machine
from being able to recognize incoming compressed packets, but it will
still generate them on the outgoing side. This is the reverse of the
desired behavior. There's no particular reason to disable the ability
to recognize incoming compressed packets. They are visibly different
from normal ones, so if the other side isn't doing compression you'll
never see one. What you want to do is turn off generation of
compressed packets. Removing the call to slhc_compress will do that.
Removing SL_COMPRESSED will not. At least not in 0.99pl11.

Presumably for pl12, Linus will put the conditional in the right place
(or preferably, allocate a flag bit to control it so that ifconfig can
be used). I believe later versions of net-2 use a somewhat more
elaborate setup, where you can disable it, enable it, or run in a mode
where compression is automatically enabled if you see a compressed
packet. (Note that it's not enough just to implement automatic
detection. One end or the other has got to be able to initiate the
compression.)