Slackware 8.0 and Ltmodem FAQ

This FAQ was written from my own experiences with the Ltmodem drivers under Slackware Linux 8.0.  
It is provided as a guide and nothing more.  I am not responsible if, 
after following the directions contained herein, your girlfriend leaves you, 
your family disowns you, your dog dies, or your computer goes up in smoke and flames.

When I first installed Slackware 8.0. I had trouble getting it to work at all, let alone get online.  
Now that I have some more experience, I am putting it down on virtual paper so that 
my experiences may help others.  Slackware is not intended to be 
a point-and-click install distro like Redhat or Caldera.  
Hence, these instructions may seem difficult to follow or complete.  
If this is the case, I recommend obtaining one of the above mentioned distros 
and downloading a precompiled installer package.  Otherwise, here we go!

To begin with, Slackware 8.0 ships with old kernels.  You will probably have 
one of the default kernels installed: one from the 2.2 series and one from the more recent 2.4 series.  
I recommend upgrading to the latest kernel release, which is 2.4.18 at the time of this writing.  
You can download it from kernel.org.  In any case, you will have to make your own custom kernel 
from whichever kernel source tree you choose, because Slackware 8 ships with 
SMP (Symmetric Multi Processor)-enabled kernels - and SMP is incompatible with 
the ltmodem driver function (this is currently true of all windmoems except the IBM mwave).
Note that you need to have the development diskset installed to do the steps below. 
IMPORTANT May 1, 2002 update.  The 8.22 series drivers are SMP comaptible.


There are extensive directions for much of the following in the README distributed 
within the kernel sources package. With minor updating, here is an excerpt needed to guide unpacking. /:-}
----------------------------------------
INSTALLING the kernel:

 - If you install the full sources, put the kernel tarball in a
   directory where you have permissions (eg. your home directory'
   or a spare partition as root).

   Do NOT use the /usr/src/linux area! This area has a (usually
   incomplete) set of kernel headers that are used by the library header
   files.  They should match the library, and not get messed up by
   whatever the kernel-du-jour happens to be.

 - Unpack the source package linux-2.4.XX.tar.gz or the more compact
   linux-2.4.XX.tar.bz2 with:

		gzip -cd linux-2.4.XX.tar.gz | tar xvf -
				or
		bunzip2 linux-2.4.XX.tar.gz | tar xvf -

   Replace "XX" with the version number of the latest kernel.
   Alternatively the tar command can be used directly, enabling a PATH usage.

               tar zxvf PATH_to/linux-2.4.XX.tar.gz  # z calling gunzip
               tar Ixvf PATH_to/linux-2.4.XX.tar.bz2 # I calling bunzip2
               tar jxvf PATH_to/linux-2.4.XX.tar.bz2 # j calling bunzip2

   where newer versions of tar use "j" rather than "I"
   Any of the above creates a kernel source tree folder

   --- Do see the section on patching skipped here, --------------------
   ----enabling Much Shorter downloads for your next kernel upgrade.----

  # su root
  (enter your root password)
  to enable making an essential symbolic link:
  # ln -sf PATH_to/linux-2.4.XX /usr/src/linux
  Move into the source folder with
              	cd /usr/src/linux
  With files shown by:  ls

COPYING        Makefile        arch             init       mm 
CREDITS        README          drivers          ipc        net     
Documentation  REPORTING-BUGS  fs               kernel     scripts  
MAINTAINERS    Rules.make      include          lib         
 
- Make sure you have no stale .o files and dependencies lying around:

		make mrproper

   You should now have the sources correctly installed.
----------------------------------------------------------------------------------- 


Now that we are in the source directory (/usr/src/linux), we can start the kernel configuration dialog:

make menuconfig

Once thing you *must* do: disable SMP support in "Processor type and features" in the kernel config 
or this entire exercise will be useless.  You can enable APIC support if you wish.

Hopefully, you have written down all the hardware information from Windows' Control Panel.  
You will see a screen with various options to include in the kernel.  
I will not go into the kernel configuration process here; 
a comprehensive guide has already been written which can (I believe) be obtained at linuxdoc.org.

Once you have finished configuring the kernel to your system's hardware specifications, 
exit the kernel configuration and save your changes. This save produces a file: .config .  
Once you are back at the command prompt, you can compile the kernel with a sequential command set like this:

make dep && make clean && make modules && make modules_install && make bzImage

or perhaps better for your first experience, step wise starting with:

make dep

Which, following the directions in the .config file, assembles the kernal headers 
with /usr/src/include/linux.  The headers are the immediate precursors for the compilations to follow.  
They distinguish your subsequent kernel+modules from all others which could have been derived the common starting sources.

At this point, a check can be done as to whether the modem drivers will compile.  
You need to unpack the ltmodem archive if you have not already done so (you should have if you are reading this document). 

tar zxvf ltmodem-6.00c1.tar.gz

change into the proper directory

cd PATH_to/ltmodem-6.00c1/

and execute the following command:

./build_module 2.4.XX

You will then be guided through the driver configuration process by the installer's automagic script.  
You can probably accept the default values given if you do not understand them. 
During the included compilation process, modem specific code is combined with the kernel headers, 
culminating in the output of a driver pair: lt_modem.o and lt_serial.o

Troubleshooting instructions will appear should failures be encountered.  
If compilation is successful, it is appropriate to finish compilations for a new kernel+modules.
    
make clean
  which removes remanants of previous compiles
make modules
  uses the kernel headers in compilation of modules
make modules_install
  puts modules into a file tree rooted at /lib/modules/2.4.n/ 
make bzImage
  compiles the kernel version and flavor matched to the modules.

Once this is completed (it may take quite a while, depending on your system), 
you need to install the newly compiled kernel and reboot.

cp arch/i386/boot/bzImage /
cd /
mv vmlinuz vmlinuz.bak
mv bzImage vmlinuz

You should check /etc/lilo.conf (e.g. with "cat /etc/lilo.conf") to make sure that 
the kernel is specified as /vmlinuz and you may have to move the kernel or edit lilo.conf appropriately. 

lilo

The "lilo" command finishes installation of the new kernel, including connecting kernels with the entries in /etc/lilo.conf 


Rebooting should put your system under control of your new kernel.  Check with:

uname -r

which outputs the kernel version.

Now it is necessary to complete the modem support. 
cd PATH_to/ltmodem-6.00c1/
you should run the following commands:

./ltinst2

Places the modem drivers into the moudles tree rooted at /lib/modules/2.4.n/ 

./autoload

makes the modem device node and appends lines enabling autoloading of the drivers to /etc/modules.conf
There is an included command:

depmod -a

which informs your System of these changes with and update the module database,

Once this has been completed, you are almost finished.  
All that is left to do is test the modem by dialing out to your ISP.  
You will want to select /dev/modem as your device.  This list recommends 
downloading and installing a program called wvdial, 
which works very well for me, but is not absolutely necessary.  
There is support for this program elsewhere.

Well, thats about it.  If you need further assistance with Slackware and the ltmodem drivers, 
I can be contacted at mohr@temerity.net.  Happy surfing, and barring that - Good Luck!

Michael Mohr
