View previous topic :: View next topic |
Author |
Message |
timotheus25 Apprentice
Joined: 27 Dec 2005 Posts: 162 Location: *upstate* New York, USA
|
Posted: Sun Jul 29, 2007 12:23 am Post subject: Dell Inspiron 640m/E1405 bootup and suspend2 |
|
|
Abstract
Making suspend2 and boot completely reliable and fast on the Dell 640m/E1405 was found to be very tricky for me with kernels 2.6.21 and 2.6.22. Various combinations of options or ordering of driver loading can cause the kernel to occasionally lockup on bootup or resume from hibernate. Using a very very modular kernel plus initramfs, with CK and suspend2, plus some specific selections for preemption, frequency, and module loading provides a very tight bootup and hibernate without any lockups. genkernel is used to automate creation of the initramfs.
Details are quoted from the source document (by yours truly):
http://tstotts.net/linux/gentooinsp640m.html.
System Details
Dell Inspiron 640m with T7200 processor.
Quote: |
Specifically from a Linux driver perspective, this machine is a
second-generation Core 2 Duo without 64-bit extensions BIOS support,
with Virtualization extensions BIOS support, Intel combined SATA/PATA
with AHCI, BIOS not supporting AHCI,
ICH7 family motherboard, synaptics touchpad,
100% maximum RAM capacity (2 GB of 2 GB).
|
Kernel configuration with initramfs
Quote: |
As of kernel 2.6.22 with CK and Gentoo patches, a particular modular
kernel setup appears to provide the maximum stability, bootup
speed, and bootup / suspend2 reliability. (Otherwise, boot-up and suspend2
appear to encounter occasional initialization lockups with respect to ACPI,
CPU hot-plugging, SLAB/SLUB, and the MSI PCI/PCI-E bus operation.) It requires
a custom initramfs for module loading of boot devices; and this example
makes use of customizing the Gentoo script =sys-kernel/genkernel-3.4.8 .
Key settings for stability with video card, bootup, suspend2, and
very fast bootup time:
- The older kernel SLAB allocator is used rather than the newer,
faster SLUB allocator introduced with kernel 2.6.22.
- Voluntary preemption, but not forced preemption, is enabled.
- Kernel is configured for NOHZ CPU operation with HZ setting of
1000.
- Kernel configured specifically for Core2 architecture, SMP
support, CPU hot-plugging, multi-core scheduling, no generic x86.
- ACPI support for processor states and thermal are compiled
directly into the kernel and not loaded as modules.
- Gensplash / bootsplash and logo are completely omitted from the
kernel.
- vesa-tng is used as video driver, compiled-in to kernel; kernel
argument specifies yrap enabled, all auto-detection disabled, with
forced mode of 1024x768-32@60.
- libata and ata_piix are loaded modularly from initramfs (after
video drivers), and prior to SCSI disk device sd_mod, with
combined mode and atapi enabled via kernel command line.
- suspend2 / tuxonice drivers are configured for swap device, and
loaded modularly after basic ATA, USB, Firewire drivers from
initramfs; and the hibernate script is configured to use
the lzf compression algorithm for speed.
- Optimal use of user-space tools toward hard drive performance,
such as =sys-apps/hdparm-7.6 and =sys-apps/readahead-list-1.20060421.1016 .
|
The custom kernel with initramfs is most easily generated with
=sys-kernel/genkernel-3.4.8 and modifying its
default settings as follows:
Contents of /usr/share/genkernel/x86/modules_load :
Code: |
MODULES_SCSI="sd_mod sg sr_mod scsi_wait_scan"
MODULES_USB="ehci-hcd hid uhci-hcd usbhid"
MODULES_SATA="libata ata_piix scsi_wait_scan"
MODULES_FS="ext3 xfs reiserfs"
MODULES_NET="b44"
MODULES_VIDEO="vesafb-tng"
MODULES_SUSPEND2="lzf suspend_userui suspend_compress suspend_swap lzf"
MODULES_FIREWIRE="firewire-ohci"
|
Last line of /usr/share/genkernel/generic/initrd.defaults :
Code: |
# modify last line to:
MY_HWOPTS='video sata scsi fs net suspend2 usb firewire'
|
Important options in /etc/genkernel.conf :
Code: |
# key options for custom kernel
MOUNTBOOT="yes"
CLEAN="no"
SAVE_CONFIG="yes"
MAKEOPTS="-j3"
|
Copy configuration from:
http://tstotts.net/files/linux/dell640m-config-2.6.22-timotheus-initramfs.txt
Putting it all together:
Code: |
genkernel --debuglevel=3 --menuconfig --install all
|
Contents of /etc/modules.autoload.d/kernel-2.6 :
Code: |
# CPUFREQ
acpi-cpufreq
cpufreq_userspace
cpufreq_conservative
non-fatal
msr
cpuid
# ACPI
button
# FILE SYSTEM
fuse
|
Example entry for: /boot/grub/grub.conf
Code: |
# line with video= kernel parameter should not wrap, but Gentoo Forums / BBCode makes it look ugly ...
#example grub menu item
title=Gentoo
root (hd0,0)
kernel /kernel-genkernel-x86-2.6.22 real_root=/dev/sda3 resume2=swap:/dev/sda2 combined_mode=libata libata.atapi_enabled=1 video=vesafb:nocrtc,noedid,gtf,ywrap,1024x768-32@60 CONSOLE=/dev/tty1
initrd /initramfs-genkernel-x86-2.6.22
|
References
CK patches: http://kernel.kolivas.org/
Tux On Ice (suspend2) patches: http://www.tuxonice.net
Gentoo patch set: http://dev.gentoo.org/~dsd/genpatches _________________ http://tstotts.net/linux/gentoopb.html
http://tstotts.net/linux/gentooinsp640m.html |
|
Back to top |
|
|
TenPin Guru
Joined: 26 Aug 2002 Posts: 500 Location: Kansas City
|
Posted: Wed Aug 15, 2007 5:04 am Post subject: |
|
|
Wow, this seems extraordinarily complicated compared to my setup.
I have an Inspiron 640m/E1405. I use Kernel 2.6.22.1 using the suspend features included in the vanilla kernel. I use suspend regularly and never have any problems. I also have all my device drivers built into the kernel except for ipw3945. When I come out of suspend my wireless reconnects instantly. _________________ For since in the wisdom of God the world by its wisdom did not know God, God was pleased to save those who believe by the foolishness of preaching. |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|