Kernel Configuration
First I installed the necessary packages to build the kernel from source with
apt-get install gcc make ncurses-dev
Then I downloaded the source code from the Linux Kernel Archives.
Used Patches
After extracting the compressed tar archive and studying the ThinkWiki a bit, I also applied some patches:
Kernel 2.6.12.x:
- the trackpoint patch
- a patch for the infrared subsystem from http://shamrock.dyndns.org/~ln/linux/, see the Infrared page for details
- Software Suspend 2 (version 2.1.9.5 for kernel 2.6.12) for Suspend-to-Disk
- manually patched the libata driver to get the optical drive to work properly, see the CD-RW/DVD-RW Multi-Burner page for details
Kernel 2.6.14:
- a patch for the infrared subsystem from http://shamrock.dyndns.org/~ln/linux/, see the Infrared page for details
The trackpoint patch has been merged into the official kernel source code, so a patch is no longer needed.
Kernel 2.6.15:
- a patch for the infrared subsystem from http://shamrock.dyndns.org/~ln/linux/, see the Infrared page for details
- a patch necessary for Suspend-to-RAM, see the Harddisk page for details
- to support some nifty features like controlling the battery charging I use the new and absolutely great tp_smapi kernel module, see http://www.thinkwiki.org/wiki/SMAPI_support_for_Linux
Configurating, Compiling and Installing the Kernel:
I used the menu configuration of the kernel via
make menuconfig
in the kernel source tree. Important settings to change are:
- in "Processor type and features" select "Pentium M" for the processor familiy to optimize for the Pentium-M
- in "Power management options (ACPI, APM)" enable ACPI (I don't use APM) and Software Suspend 2. Note: to use a newer version of the "IBM ThinkPad Laptop Extras" you have to compile it as module so it can be easily replaced later on.
- enable CPU frequency scaling, select scaling governors ("ondemand" and "conservative" are the ones I use, but be sure to also select "userspace" if you want some external program like cpufreqd to do the frequency scaling) and enabe the processor driver for Centrino ("Intel Enhanced SpeedStep")
- for the harddisk SCSI has to be enabled and in the low-level SCSI drivers section Serial ATA and "Intel PIIX/ICH SATA support" need to be selected
- to get the kernel to recognize the CD-RW/DVD-RW I also needed to enable ACPI Plug'n'Play support (and of course the ATAPI/IDE CD-ROM driver)
My currently used kernel configuration (for each version of the kernel) is attached at the bottom of this page.
Afterwards I compilied the kernel by issuing
make
and after switching to the root account I installed the kernel modules, the System.map file and the kernel image with
make modules_install
cp System.map /boot/System.map-2.6.12.3
cp arch/i386/boot/bzImage /boot/vmlinuz-2.6.12.3
Then I added a new entry in the GRUB menu file in /boot/grub/menu.lst:
title Debian GNU/Linux, kernel 2.6.12.3
root (hd0,5)
kernel /boot/vmlinuz-2.6.12.3 root=/dev/sda6 ro video=vesafb,nomtrr,ywrap vga=836 acpi_sleep=s3_bios resume2=swap:/dev/sda5 processor.max_cstate=2 elevator=cfq
Note: not all of the kernel parameters are necessary, video and vga give a higher resolution in the text consoles (if the vesa framebuffer driver is compiled into the kernel), resume2 is for Software Resume 2, elevator=cfq selects a different scheduling mechanism more suitable for desktop use, acpi_sleep is needed to circumvent a problem with suspend-to-ram.
Since switching to SCSI-SATA also meant that the harddisk would be called /dev/sda after the reboot, I also changed all occurences of "/dev/hda" to "/dev/sda" in /etc/fstab.
One
init 6
later and I was running the shiny new kernel.
| Attachment | Size |
|---|---|
| config-2.6.12.3 | 38.95 KB |
| config-2.6.14 | 41.76 KB |

Comments
RC9 works for me but suspend-to-ram crashes my box
Hello!
I tested suspend-to-ram and suspend2 and after suspend-to-ram with my hibernate.conf i got a oops too. Your config do not work with my box.
I have a T43.
CU
Michael
suspend2 and suspend-to-ram
seems not possibly atm, at least not at the same time, I ponder doing one kernel patched with suspend2 and one with the suspend-to-ram patches applied, since I need both occasionally, although the later is more important to me.
But I'm sure that once the suspend-to-ram stuff enters the vanilla kernels (and that's just a matter of time) both will work happily in combination.
BTW, can you give me any hints what exactly doesn't work with the config? (you mean the hibernate.conf, right?)
thanks!
thanks for posting your config file(
!
FileSystem
Hello,
thanks for you configs file. Just a note : You should say that they are written for ext3 FS, because I spent about 1 hour trying to understand why my system keeped on crashing, and it was because of my FS (Reiser) isn't included in the kernel in your conf file.
sorry
if I caused you troubles... it's just that my configs are just meant to be a help for getting the Thinkpad-specific stuff up and runniing, and things like filesystems and of course also all used peripherals etc. are different for everyone. But I'll put a note of warning above the text.
Can you write your grub config for 2.6.14
Hello!
Can you write the grub config for kernel 2.6.14. I want to know, which is different to my config, Maybe i find the reason why suspend-to-ram crashs.
grub config for 2.6.14.3
the kernel line (which is probably the only interesting one) looks like:
config for 2.6.15
Can you post a kernel config for 2.6.15?
Thanks
it's the same as for 2.6.14
just updated with "make oldconfig".
Kernel 2.6.16
Which patches are necessary for kernel 2.6.16?
Can you write your grub config for this kernel version?
Any idea? Thanks Marco
Any idea?
Thanks
Marco