Slackware 9.1 /10.0 Linux on the Dell Latitude D500

Kees Lemmens

October 2003, Version 1.3 : November 2004

The Dell Latitude D500 needs some more work to make Linux run properly than most other laptops. However, with the following tips you should be able to have a reasonable laptop running Slackware 9.1 or 10.0 Linux with sound, pcmcia, video and modem.

1  Partitiontable

I decided to leave the Dell Utility partition in place : it is just small and you never know what it may be good for.

My partitiontable now looks as follows:

root@dell1:~# fdisk -l /dev/hda

Disk /dev/hda: 40.0 GB, 40007761920 bytes
255 heads, 63 sectors/track, 4864 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/hda1               1           6       48163+  de  Dell Utility
/dev/hda2   *           7         615     4891792+  83  Linux
/dev/hda3             616        3048    19543072+  83  Linux
/dev/hda4            3049        4864    14587020    5  Extended
/dev/hda5            3049        3065      136521   82  Linux swap
/dev/hda6            3066        4864    14450436    b  W95 FAT32

I prefer to have Linux on primary partitions. Swap is less critical and MS-Windows is not installed and probably never wil be, so these may reside happily in an extended partition :)

2  PCMCIA

Running /etc/rc.d/rc.pcmcia completely locks the system !!!! You have to disable it (chmod 644 /etc/rc.d/rc.pcmcia) or you cannot even boot up. To do this you can boot once in single usermode to bypass the rc.pcmcia being executed (and thus hanging your system :)

LILO BOOT : linux s

After some detective work I found a simple way to get pcmcia running : You have to forbid pcmcia to include ports in the range 0x800-0x8ff. You can do that in /etc/pcmcia/config.opts :

Change :

   include port 0x100-0x4ff, port 0x800-0x8ff, port 0xc00-0xcff

Into :

        include port 0x100-0x4ff, port 0xc00-0xcff

Then reenable the rc.pcmcia script (chmod 755 /etc/rc.d/rc.pcmcia). After this it will work fine !!

3  Console screen

The video has standard only 1 MByte available. This is not enough for 1024x768x16, but 1024x768x8 fits nicely so I changed the vga line in /etc/lilo.conf to vga=773 to force a framebuffer console.

Don't use a standard console screen (vga=normal), as this sometimes becomes corrupted : a framebuffer console is much less error prone.

4  Xserver

Using an Xserver on the framebuffer works fine, but as it can only use 256 colors it looks very ugly. This is why I choose to use the dedicated i810 Xserver module as it is much faster and has more features (3D, XV-Video etc.).

Initially I used a small tool to reprogram the amount of available videomemory on this videocard : 855patch. However, since Xfree 4.4.0 (or Xorg) this is not necessary anymore as it is incorporated into the Xserver itself.

In case you still need it (e.g. your using Xfree 4.30 or earlier) just download (use Google) and compile it using the following commands :

su -
mkdir -p /local/source
cd /local/source
tar -xvzf <location_of_855patch_tar>/855patch.tar.gz
cd 855patch
make
cp 855patch /root

I stored the 855patch executable in /root. To load it at boottime just add the following line somewhere to e.g. /etc/rc.d/rc.modules :

        /root/855patch 16384

Using xfree86setup to generate a XF86Config file for 24-bit color 1024x768 worked fine. I use to type "X" on the commandline to see if it works indeed and after that you may safely change the runlevel to 4.

After some weeks I found out that the mouse-cursor sometimes disappeared mystereriously. For this reason I decided to use a soft-cursor and that indeed solved the problem :

In /etc/X11/XF86Config : add the following Option :

        Option "SWCursor" "true"

This however makes 3D rendering of my favorite Modelplane Flight Simulator ''Crrcsim'' much slower, so if you really want 3D it would be better to stick to the hardware cursor.

4.1  Console switching

There were some reports about trashing the videomemory when switching to a normal console but with framebuffer on the console I wasn't able to reproduce this. However the standard console (vga=normal) indeed had some problems which is why I decided to use the framebuffer instead.

4.2  Blank screen after closing the laptop cover

One more thing that annoyes me : if you close the laptop (or push the tiny button just below the TFT screen) the screen goes blank and there seems to be no way to wakeit up again. However, what works is switch to a console (Ctrl-Alt-F1) and then go back to the graphics screen (Ctrl-Alt-F7 or similar).

Update Nov 2004 : In Xfree 4.4 or Xorg the screen returns after opening the cover but seems to be garbled at the top (see also below). A solution is to do the same as above.

4.3  3D stuff

3D DRI works fine under the following conditions :

4.4  External monitor or beamer

Connecting a beamer proved to be far more cumbersome than on most other laptops : switching using the Fn-F8 key combination allows either for TFT or extern but NOT both at the same ! For presentations this is a disaster : after more than half an hour you'll be sure to end up with a stiff neck ;>)

To make things more nasty : since Xfree 4.4.x/Xorg switching from internal to external or vv. confuses the videochip and results in a ugly bar of about 50 pixels with debris on top.

After searching for weeks (the Dell helpdesk of course had no answer ;) I found a small tool that allows turning the external monitor on and off without affecting the local TFT screen.

The tool is called i810switch and I downloaded (use Google) and compiled it using the following commands :

su -
mkdir -p /local/source
cd /local/source
tar -xvzf <location_of_i810switch_tar>/i810switch-0.6.2.tar.gz
cd i810switch-0.6.2
make
cp i810switch /usr/local/bin
chmod u+s /usr/local/bin/i810switch  # allow normal users to use the tool !

This tool usually works fine, but on several beamers the signal from the VGA output is very unclear and unstable, with a lot flickering and dither, sigh ...

Update Nov 2004 : I found a new tool i855crt by Andrea Merello from Italy called i855crt and this one works perfectly well because he uses a different technique to address the external VGA connector.

To get it : http://sourceforge.net/projects/i855crt

Compile and install :

su -
mkdir -p /local/source
cd /local/source
tar -xvzf <location_of_i855crt_tar>/i855crt-0.4.tar.gz
cd i855crt-0.4
make
mkdir /usr/local/i855crt-0.4
cp i855crt i855crt.conf COPYING README /usr/local/i855crt-0.4
chmod u+s /usr/local/i855crt-0.4/i855crt  # allow normal users to use the tool !

To use the tool in an easy way I created a small wrapper script crt_toggle that I installed in /usr/local/bin. This will just turn the beamer on when it is off and vice-versa. I also made a small desktop icon called ``Beamer'' on my screen that simply calls this script.

#!/bin/sh
# Kees Lemmens, November 2004

I855BASE=/usr/local/i855crt-0.4
CRTMODE=1024x768@70
TOGGLE=/tmp/.$CRTMODE-$USER.on
I855CRT=$I855BASE/i855crt
BASE=$( basename $0 )

cd $I855BASE # need this to be able to find config file

test -r $TOGGLE &&
{
  $I855CRT off
  rm -f $TOGGLE
} ||
{
  $I855CRT swcursor overlaycrt on $CRTMODE
  touch $TOGGLE
}

5  Soundcard

Initially I used the Slackware Alsa drivers as detected by hotplug. However, this alsa-driver-0.9.6 had some problems with the OSS emulation so I tried the OSS module from the kernel :

/etc/rc.d/rc.modules : /sbin/modprobe i810_audio

But things don't always come easy, this one sometimes had problems with the speed of replay : on several occasions it just played much too fast or too slow.

After this I decided to install the latest Alsa drivers (0.9.8) and these work fine ! They even made the internal modem finally work (with help of the pctel drivers).

To install alsa-driver-0.9.8 (see http://www.alsa-project.org/) :

su - 
mkdir -p /local/source
cd /local/source
tar -xvjf <location_of_alsa_tarfile>/alsa-driver-0.9.8.tar.bz2
cd alsa-driver-0.9.8
./configure --prefix=/usr/local --with-sequencer=yes --with-oss=yes \
  --with-cards=dummy,ens1371,via82xx,intel8x0
make
make install

To load the driver at boot time create the following script :

/usr/local/etc/rc.alsa-intel8x0

#!/bin/sh
# Kees Lemmens, Oct 2003

echo "Loading Alsa sounddrivers ..."

/sbin/modprobe snd-intel8x0
/sbin/modprobe snd-seq-midi

# OSS emulation stuff :
/sbin/modprobe snd-pcm-oss
/sbin/modprobe snd-mixer-oss
/sbin/modprobe snd-seq-oss

chmod 666 /dev/{mixer,dsp,adsp,midi,sequencer}*

And add this script to /etc/rc.d/rc.local.

6  Hotplug probing

Although rc.hotplug did not hang the system, it gave so many warnings that I decided to disable it completely and set the few modules that I needed by hand. However, adding the troublemakers to /etc/hotplug/blacklist may fix the warnings as well.

To start the networkcard manually :

/etc/rc.d/rc.netdevice : /sbin/modprobe eepro100

7  ACPI powersaving

The battery power indicator and the automatic power-off after a shutdown only works if you install a kernel with ACPI support. You can take the bareacpi kernel from the Slackware CD if you want the easy way out. And ... don't forget to run LILO after replacing your kernel :)

The klaptop battery indicator (lowerright in toolbar under KDE) works fine afterwards.

8  Builtin modem (WinModem)

Wonder Oh Wonder : after installing the latest Alsa sound modules I was also able to get the internal WinModem working !

I obtained the pctel drivers pctel-0.9.7-6.tar.gz (use Google to find it).

Afterwards :

su - 
mkdir -p /local/source
cd /local/source
tar -xvzf <location_of_pctel_tarfile>/pctel-0.9.7-6.tar.gz
cd pctel-0.9.7-6
./install
Enter modetype -> i8xx (as the autodetect currently fails)
mkdir -p /lib/modules/2.4.22/kernel/misc
cp driver/*.o /lib/modules/2.4.22/kernel/misc/
depmod -a

insmod -f pctel
insmod -f ptserial irq=11 iobase=0xd400 iobase1=0xd080
rm -f /dev/ttyS15 && mknod /dev/ttyS15 c 62 79
ln -sf /dev/ttyS15 /dev/modem
chmod 666 /dev/modem

Note that we did recreate the ttyS15 device : for some reason the existing /dev/ttyS15 has a different major number which is why it will never work with that one !! Just remove the old one and create a new correct one.

Also don't bother about the warnings over compiler version mismatch and tainted modules :they are not important for the modem : it works fine. You may redirect them to /dev/null if you prefer by appending > /dev/null to the insmod lines.

The last 5 lines (2x insmod , rm+mknod, ln and chmod) can best be added to /etc/rc.d/rc.local to make the modem automatically available after every reboot.

After that you can use kppp to login into the internet through your local provider account.


File translated from TEX by TTH, version 2.58.
On 28 Oct 2005, 10:47.