⇐ table of contents | previous section | next section ⇒
Everytime we buy a new laptop, we are amazed about the lack of useful documentation about the actual hardware configuration and its capabilities. IBM's customer support website features an overwhelming amount of downloadable information — which turns out to be mostly irrelevant or dumbed down beyond any usefulness.
Our current kernel configuration is based on many guesstimates. It seems to work, though. But remember: This story is for your entertainment only. If you use this kernel configuration “as is” without reading and understanding the somewhat more detailed sections below, you will almost certainly damage your precious Thinkpad.
—— Code Maturity Level Options ——
yes Promt for development and/or incomplete code/drivers
—— Loadable Module Support ——
yes Enable loadable module support
yes Set version information on all modules
yes Kernel modules loader
—— Processor Type And Features ——
Pentium-4 Processor family
off High Memory support
yes MTRR (Memory Type Range Regsiters) support
—— General Setup ——
yes Networking support
yes PCI support
any PCI access mode
yes PCI device name database
yes Support for hot-pluggable devices
—— PCMCIA/Cardbus support ——
yes PCMCIA/Cardbus support
yes CardBus support
yes System V IPC
yes Sysctl support
ELF Kernel core
yes Kernel support for ELF binaries
mod Kernel support for MISC binaries
yes Power Management support
yes Advanced Power Management BIOS support
yes Enable PM at boot time
yes Make CPU idle calls when idle
yes Enable console blanking using APM
yes RTC stores time in GMT
yes Allow interrupts during APM BIOS calls
—— Block Devices ——
mod Loopback device support
mod Network block device support
—— Multi-Device Support (RAID and LVM) ——
yes Multiple devices driver support (RAID and LVM)
yes Logical volume manager (LVM) support
—— Networking Options ——
yes Packet socket
yes Packet socket: mmaped IO
yes Socket Filtering
yes Unix Domain Sockets
yes TCP/IP Networking
yes IP: TCP syncookie support (disabled by default)
—— ATA/IDE/MFM/RLL Support ——
yes ATA/IDE/MFM/RLL support
—— IDE, ATA and ATAPI Block devices ——
yes Enhanced IDE/MFM/RLL disk/cdrom/tape/floppy support
yes Include IDE/ATA-2 DISK support
yes Use multi-mode by default
yes SCSI emulation support
yes Generic PCI IDE chipset support
yes Sharing PCI IDE interrupts support
yes Generic PCI bus-master DMA support
yes Use PCI DMA by default when available
yes Intel PIIXn chipsets support
yes PIIXn tuning support
—— SCSI Support ——
yes SCSI support
mod SCSI CD-ROM support
yes Enable vendori-specific extensions (for SCSI CDROM)
2 Maximum number of CDROM devices that can be loaded as modules
mod SCSI generic support
yes Enable extra checks in new queuing code
—— SCSI low-level drivers ——
mod Adaptec AIC7xxx support
253 Maximum number of TCQ commands per device
15000 Initial bus reset in milli-seconds
—— Network Device Support ——
yes Network device support
mod Dummy net driver support
—— Ethernet (10 or 100Mbit) ——
yes Ethernet (10 or 100Mbit)
yes EISA, VLB, PCI and on board controllers
mod EtherExpressPro/100 support
mod PPP (point-to-point protocol) support
mod PPP support for async serial ports
mod PPP Deflate compression
—— PCMCIA network device support ——
yes PCMCIA network device support
mod 3Com 3c589 PCMCIA support
—— Input Core Support ——
yes Input core support
yes Mouse support
1600 Horizontal screen resolution
1200 Vertical screen resolution
—— Character Devices ——
yes Virtual terminal
yes Support for console on virtual terminal
mod Standard generic (8250/16550 and compatible UARTs) serial support
yes Unix98 PTY support
256 Maximum number of Unix98 PTYs in use (0-2048)
—— Mice ——
yes Mouse support (not serial and bus mice)
yes PS/2 mouse (aka “auxiliary device” device) support
yes /dev/nvram support
yes Enhanced Realtime Clock support
yes /dev/agpgart (AGP Support)
yes Intel 440LX/BX/GX and i815/i830M/i840/i850 support
yes Direct Rendering Manager (XFree86 DRI support)
mod ATI Radeon
—— PCMCIA character devices ——
mod PCMCIA serial device support
—— File Systems ——
yes Ext3 journalling file system support
mod DOS FAT fs support
mod MSDOS fs support
mod ISO 9660 CDROM file support
yes Microsoft Joliet CDROM extensions
yes Transparent decrompression extensions
yes /proc file system support
yes /dev/pts file system for Unix98 PYTs
yes Second extended fs support
mod UDF file system support (read only)
—— Native Language Support ——
iso8859-1 Default NLS Option
mod Codepage 437 (United States, Canada)
mod Codepage 850 (Europe)
mod Japanese charsets (Shift-JIS, EUC-JP)
mod NLS ISO 8859-1 (Latin 1; Western European Languages)
mod NLS UTF-8
—— Console Drivers ——
yes VGA text console
yes Video mode selection support
—— Frame-buffer support ——
yes Support for frame buffer devices
yes ATI Radeon display support
—— Sound ——
mod Sound card support
mod Intel ICH (i8xx) audio support
—— USB Support ——
yes Support for USB
yes UHCI Alternate Driver (JE) support
yes USB HIDBP Mouse (basic) support
—— Kernel Hacking ——
yes Kernel debugging
yes Magic SysRq key
|
Note: As far as we understand has the Intel 82801 CAM I/O Controller Hub neither random generator nor watchdog functions.
⇐ table of contents | top ⇒
First of all, we want the VESA Framebuffer for our text consoles to make use of our nice screen resolution. In addition, we get a cuddly penguin boot logo at no extra cost. For this to work, we need to configure the kernel to support the VESA Framebuffer and then set the VGA mode in /etc/lilo.conf.
—— Console Drivers ——
yes VGA text console
yes Video mode selection support
—— Frame-buffer support ——
yes Support for frame buffer devices
yes VESA VGA graphics console
|
Mode: LILO: Graphics: Text: 0x318 vga=792 1024x 768 128x48 0x31b vga=795 1280x1024 160x64 0x374 vga=884 1600x1200 200x74 |
image=/boot/vmlinuz label=linux read-only vga=884 image=/boot/vmlinuz.old label=backup read-only vga=normal optional |
⇐ table of contents | top ⇒
Our graphic chip is an ATI Mobility FireGL 7800, which seems to be quite similar to the ATI Mobility M6 type of chips. The card reports itself in /proc/pci as device 1002:4c58 (ATI Technologies Inc) (rev0).
Unfortunately, the ATI FireGL 7800 is not (yet) supported by the Linux Radeon Framebuffer. But with a little bit of hacking, we can make it so. In /usr/src/kernel-source-2.4.18/drivers/video/radeon.h we redifine the RADEON_LW type to our ID number and then reconfigure the kernel.
—— Console Drivers ——
yes VGA text console
yes Video mode selection support
—— Frame-buffer support ——
yes Support for frame buffer devices
yes ATI Radeon display support
|
#define PCI_DEVICE_ID_RADEON_LW 0x4c57 /* original */ #undef PCI_DEVICE_ID_RADEON_LW #define PCI_DEVICE_ID_RADEON_LW 0x4c58 /* dirty hack */ |
⇐ table of contents | top ⇒
Frankly we don't know whether the fbdev or the patched radeon XFree86 servers really make use of the Direct Rendering Infrastructure (DRI). Support for it does not hurt us, though.
—— Character Devices ——
yes /dev/agpgart (AGP Support)
yes Intel 440LX/BX/GX and i815/i830M/i840/i850 support
yes Direct Rendering Manager (XFree86 DRI support)
mod ATI Radeon
|
At boot time, somebody or something tries to access DRI but does not how to do so. This produces the error message:
[date] [machine] modprobe: Can't locate module-char-major-226 |
To help out, we create the file /etc/modutils/dri and update /etc/modules.conf.
alias char-major-226 radeon # DRI |
#> update-modules |
⇐ table of contents | top ⇒
According to /proc/pci, the the IEEE1394 Firewire Controller is a 1180:0552 (Ricoh Co Ltd) (rev 0), which is of the OHCI-1394 type. To make use of our external LaCie Firewire Hard Disk, we have to configure for IEEE 1394, OHCI 1394, SBP-2 as well as SCSI disk support.
—— IEEE1394 (FireWire) Support ——
mod IEEE 1394 (FireWire) support
mod OHCI-1394 support
mod SBP-2 support (Harddisks etc.)
mod Raw IEEE 1394 I/O support
|
—— SCSI Support ——
yes SCSI support
mod SCSI disk support
2 Maximum number of SCSI disks that can be loaded as modules
yes Enable extra checks in new queuing code
|
The actual configuration necessary to access the external hard disk is described in a different section.
⇐ table of contents | top ⇒
The CardBus (PCMCIA) controllers are Ricoh RL5c476 II (rev 168) devices, which are supported by the standard kernel. Since the standard kernel supports driver hotplugging, we don't have to install any special PCMCIA drivers any longer. All we have to do, is to install the packages providing the necessary infrastructure and then configure the kernel for our cards, i.e. the 3COM 3CCM156 Modem PC-Card, 3COM 3CCE589EC Ethernet PC-Card, and the Adaptec APA1480A CardBus-Card.
pcmcia-cs hotplug usbutils |
—— General Setup ——
yes Networking support
yes Support for hot-pluggable devices
—— PCMCIA/Cardbus support ——
yes PCMCIA/Cardbus support
yes CardBus support
—— Character Devices ——
mod Standard generic (8250/16550 and compatible UARTs) serial support
—— PCMCIA character devices ——
mod PCMCIA serial device support
—— Networking Options ——
yes TCP/IP Networking
—— Network Device Support ——
yes Network device support
—— PCMCIA network device support ——
yes PCMCIA network device support
mod 3Com 3c589 PCMCIA support
—— SCSI Support ——
yes SCSI support
mod SCSI generic support
yes Enable extra checks in new queuing code
—— SCSI low-level drivers ——
mod Adaptec AIC7xxx support
253 Maximum number of TCQ commands per device
15000 Initial bus reset in milli-seconds
|
⇐ table of contents | top ⇒
The sound chip in this Thinkpad is an Intel 82801CAM (ICH3-M) using a AC'97 front end. Although the standard kernel sound driver seems to work, we prefer to install the ALSA sound drivers (version 0.9). To do so, we need to install the relevant Debian packages and configure the kernel for general sound support.
alsa-base (v0.9) alsa-source (v0.9) alsa-utils (v0.9) libassound2 (v0.9) alsaconf debhelper debconf-util html2text |
—— Sound
mod Sound card support
|
During the configuration of the alsa-source package, we select the intel8x0 and mpu401 drivers without ISAPnP from the menu. To compile the alsa-source package, we used again make-kpkg.
#> cd /usr/src #> tar xzf alsa-driver.tar.gz #> cd kernel-source-2.4.18 #> make-kpkg -rev Custom.1 modules_image #> cd .. #> dpkg -i alsa-modules-2.4.18_0.9+0beta12+3+p0+Custom.1_i386.deb |
Finally, we must configure the alsa sound modules. To this end, we run alsaconf, select “0x31 Intel_i810/810E,i820,i840,MX440” as our card, choose some parameters and then update-modules.
#> alsaconf #> update-modules |
Unfortunately, there seems to be a bug in alsaconf, which makes it necessary to edit the resulting configuration file by hand, i.e. we have to replace the first occurence of “snd-card-intel8x0” with “snd-intel8x0”.
# ALSA alias char-major-116 snd alias snd-card-0 snd-intel8x0 # OSS/Free alias char-major-14 soundcore alias sound-slot-0 snd-card-0 # Soundcard alias sound-service-0-0 snd-mixer-oss alias sound-service-0-1 snd-seq-oss alias sound-service-0-3 snd-pcm-oss alias sound-service-0-8 snd-seq-oss alias sound-service-0-12 snd-pcm-oss options snd snd_major=116 snd_cards_limit=1 snd_device_mode=0666 snd_device_gid=29 snd_device_uid=0 options snd-card-intel8x0 snd_index=0 snd_id=CARD_0 snd_pbk_frame_size=128 snd_cap_frame_size=128 snd_mic_frame_size=128 |
Note: It is currently not advisable to install timidity together with the ALSA 0.9 version. timidity insists on installing the old version of libasound2. The following error message while trying to launch alsamixer is a strong hint that the old version of libasound2 got installed on top of the new one:
#> alsamixer ALSA lib control.c:601:(snd_ctl_open_noupdate) Invalid CTL default alsamixer: function snd_ctl_open failed for default: No such file or directory |
⇐ table of contents | top ⇒
The internal modem is again based on the Intel 82801CAM chip in combination with the AC'97. This is one of these (literally) braindead “winmodems”. According to the Linmodem-HOWTO, this specific spawn of engineering is not (yet) supported.
⇐ table of contents | top ⇒
The ethernet adapter is an Intel 82801CAM (ICH-3) (rev66) controller, which is supported by the EtherExpressPro/100 driver.
—— General Setup ——
yes Networking support
—— Networking Options ——
yes TCP/IP Networking
—— Network Device Support ——
yes Network device support
—— Ethernet (10 or 100Mbit) ——
yes Ethernet (10 or 100Mbit)
yes EISA, VLB, PCI and on board controllers
mod EtherExpressPro/100 support
|
For the semi-automagic configuration of the ethernet-device, we must have an active network connection when we boot the Debian installation system. If this is not the case during the installation of the etherconf package, dpkg-reconfigure etherconf is our friend.
etherconf libconfhelper-perl liblogfile-rotate-perl |
If we want that the modular ethernet driver is loaded automagically, we have to create the file /etc/modutils/eth0 and then update /etc/modules.conf:
alias eth0 eepro100 # kernel ethernet driver for EtherExpressPro/100 |
#> update-modules |
Intel offers an alternate driver for the PRO/100 ethernet controllers. It was only a little bit hard to find in that corporate bloat of slowly, not completely or not at all loading graphics and scripts, since we did not know the filename of the tar-ball we were looking for. The subsequent compilation and installation of this driver is, however, completely painless. We only have to remember to register the new module afterwards.
#> cd /usr/src #> tar -xzf e100-2.1.15.tar.gz #> cd e100-2.1.15/src #> make clean #> make install |
# alias eth0 eepro100 # kernel ethernet driver for EtherExpressPro/100 alias eth0 e100 # intel ethernet driver for EtherExpressPro/100 |
Note: In newer kernel versions (2.4.20), this driver is now part of the kernel-source package and needs no longer be installed separately.
⇐ table of contents | top ⇒
The 802.11b wireless network card shows up as an 1260:3873 (Harris Semiconductor) (rev1), but is in reality an Actiontec 802MIP, which is supported by the linux-wlan Project. The corresponding Debian packages are available in the “unstable” (a.k.a. “sid”) distribution:
wireless-tools-25 linux-wlan-ng linux-wlan-ng-modules-2.4.18 |
Due to a plethora of unmet dependencies it is not possible to just install these three binary packages on our “woody” based system. We have to compile the kernel modules as well as the support packages from source — as task which we defer to the next chapter.
However, since our wireless router wants us to connect via DHCP, we have to configure the kernel for Packet Socket and Socket Filtering:
—— Networking Options ——
yes Packet socket
yes Packet socket: mmaped IO
yes Socket Filtering
|
⇐ table of contents | top ⇒
Bluetooth is attached via the Intel 82801CAM (ICH3-M) USB controllers. This setup is supported by BlueZ, the Official Linux Bluetooth Protocol Stack.
As we don't have any bluetooth devices, we don't configure Bluetooth.
⇐ table of contents | top ⇒
The IDE controller is an Intel 82801CAM (ICH3-M). The hard disk is an IBM Travelstar 60GH ATA-5 with 60.01GB capacity. The controller seems to be similar to the Intel PIIX4 chipset. Everything is nicely supported by the kernel:
—— ATA/IDE/MFM/RLL Support ——
yes ATA/IDE/MFM/RLL support
—— IDE, ATA and ATAPI Block devices ——
yes Enhanced IDE/MFM/RLL disk/cdrom/tape/floppy support
yes Include IDE/ATA-2 DISK support
yes Use multi-mode by default
yes Generic PCI IDE chipset support
yes Sharing PCI IDE interrupts support
yes Generic PCI bus-master DMA support
yes Use PCI DMA by default when available
yes Intel PIIXn chipsets support
yes PIIXn tuning support
|
⇐ table of contents | top ⇒
The DVD/CD-RW combi drive is a Matsushita UJDA 730 ATAPI DVD/CD-RW, which we want to use as an “SCSI-over-IDE” device. Additionally we have an Adaptec APA-1480A CardBus SCSI controller to connect our scanner.
—— ATA/IDE/MFM/RLL Support ——
yes ATA/IDE/MFM/RLL support
—— IDE, ATA and ATAPI Block devices ——
yes Include IDE/ATA-2 DISK support
—— SCSI Support ——
yes SCSI support
mod SCSI CD-ROM support
yes Enable vendori-specific extensions (for SCSI CDROM)
2 Maximum number of CDROM devices that can be loaded as modules
mod SCSI generic support
yes Enable extra checks in new queuing code
—— SCSI low-level drivers ——
mod Adaptec AIC7xxx support
253 Maximum number of TCQ commands per device
15000 Initial bus reset in milli-seconds
|
Note: If we configure for multiple LUN probing, we will end up with 7 CD-ROM devices as the DVD/CD-RW drive responds to all probed LUNs.
We have to inform lilo about our setup by editing /etc/lilo.conf:
image=/boot/vmlinuz label=linux read-only vga=792 append="hdc=ide-scsi" |
The DVD/CD-RW drive shows up as Host: scsi0 Channel: 00 Id: 00 Lun: 00 and as the first SCSI CD-ROM, i.e. /dev/scd0. For convenience, we install symlinks for /dev/cdrom, /dev/dvd and /dev/cdrw.
#> rm /dev/cdrom /dev/dvd /dev/cdrw #> ln -s /dev/scd0 /dev/cdrom #> ln -s /dev/scd0 /dev/dvd #> ln -s /dev/scd0 /dev/cdrw |
Finally we also have to update /etc/fstab.
/dev/hda1 /boot ext2 defaults,ro 0 2 /dev/hda2 none swap sw 0 0 /dev/hda5 / ext2 defaults,errors=remount-ro 0 1 /dev/disk/usr /usr ext3 defaults,ro 0 2 /dev/disk/var /var ext3 defaults,errors=remount-ro 0 2 /dev/disk/tmp /tmp ext2 defaults,errors=remount-ro 0 2 /dev/disk/cdr /cdr ext3 defaults,errors=remount-ro 0 2 /dev/disk/home /home ext3 defaults,errors=remount-ro 0 2 /dev/scd0 /mnt/cdrom iso9660 user,ro,nosuid,nodev,exec,noauto 0 0 /dev/scd0 /cdrom iso9660 defaults,noauto 0 0 proc /proc proc defaults 0 0 none /dev/pts devpts gid=5,mode=620 0 0 |
After inserting the APA 1480A card, the scanner shows up as Host: scsi1 Channel: 00 Id: 00 Lun: 00 and as the second generic SCSI device, i.e. /dev/sg1. Unfortunately, the AIC7xxx driver is apparently not hot-un-pluggable. In other words, we must shutdown the machine to remove the SCSI card. Otherwise the kernel will panic sooner or later — with unpredictable consequences for the rest of the SCSI subsystem.
⇐ table of contents | top ⇒
There is nothing new in our kernel configuration for Logical Volume Management (LVM). We can add, however, a few cosmetic configurations.
—— Multi-Device Support (RAID and LVM) ——
yes Multiple devices driver support (RAID and LVM)
yes Logical volume manager (LVM) support
|
The LVM library scans for a bunch of devices while heading to find disks. If these are not supported by the kernel, the module loader tries to find and load the corresponding kernel modules. This produce somes error messages, which we can easily avoid.
[date] [machine] modprobe: Can't locate module block-major-8 [date] [machine] modprobe: Can't locate module block-major-33 [date] [machine] modprobe: Can't locate module block-major-34 |
block-major-8 are SCSI disk devices, block-major-33 and block-major-33 the third and forth IDE hard disk/CD-ROM interfaces. As we don't have any SCSI disks and don't access the CD-ROM as an IDE device, we can create /etc/modutils/lvm-exclude and then update /etc/modules.conf to make LVM shut up.
alias block-major-8 off # SCSI disks alias block-major-33 off # 3rd IDE controller alias block-major-34 off # 4th IDE controller |
#> update-modules |
Note: We have to be careful about the block-major-8 entry and should probably remove it, if we want to access IEEE1394 FireWire hard disks.
⇐ table of contents | top ⇒
Thanks to our acrobatics while partitioning the hard disk, everything works now out of the box. However, with such a large amount of RAM to write to or read from disk, shutting down the machine and rebooting is likely to be quite a bit faster than hibernating.
—— General Setup ——
yes Power Management support
yes Advanced Power Management BIOS support
yes Enable PM at boot time
yes Make CPU idle calls when idle
yes Enable console blanking using APM
yes RTC stores time in GMT
yes Allow interrupts during APM BIOS calls
|
Note: The last option “Allow interrupts during APM BIOS calls” is required for APM to work on out Thinkpad.
⇐ table of contents | top ⇒
There exists tpctl, a nifty package with a suite of small programs, which let us talk directly to some of the hardware in our Thinkpad.
thinkpad-base thinkpad-source tpctl |
No special configuration is necessary for the Thinpad kernel-modules. We only need to unpack the tar-ball, recompile the kernel, install it and then try to find out what all those nice options in (n)tpctl really are for.
#> cd /usr/src #> tar xzf thinkpad.tar.gz #> cd kernel-source-2.4 #> make-kpkg -rev Custom.1 kernel_image #> make-kpkp -rev Custom.1 modules_image #> cd .. #> rm -rf /lib/modules/2.4.18 #> dpkg -i kernel-image2.4.18_Custom.1_i386.deb #> dpkg -i alsa-modules-2.4.18_0.9+beta12+3+p0+Custom.1_i386.deb #> dpkg -i thinkpad-modules-2.4.18_3.5-1+Custom.1_i386.deb |
⇐ table of contents | top ⇒
Another nice program is tpb (ThinkPad Buttons), which monitors volume, brightness and other settings by analysing the NVRAM. If we want to make use of this tool, we have to configure the kernel for NVRAM support.
—— Character Devices ——
yes /dev/nvram support
|
⇐ table of contents | previous section | next section | top ⇒