I have a Lenovo Thinkpad T420s with the following main features:
- Intel Core i7 2640M 2.8GHz
- 4GB RAM, 160GB SSD
- 14" TFT
- Wifi Ultimate-N 6300, WiMAX (what's that BTW?), WWAN UMTS/3G Ericsson F5521
- Hybrid grahics (Intel HD plus nVidia Optimus, NVS 4200M)
As you can see, that's a beast
Nevertheless, it has dual boot (I kept the original Windows 7 in a separate partition), and in Windows the battery life is significantly longer (at least 3h or so) and the laptop is in general much cooler (and the fan much more silent). In Gentoo the battery lasts at most 2h without even stressing the CPU.
I've been improving this a bit, thanks to many hints found in thinkwiki.org and other sites (including these Gentoo forums). I've found the PowerTOP utility specially interesting.
But I've reached a point where I don't know what else to do. So that's why I write you, hoping that somebody can clearly see something that I may be doing wrong...
I use to travel rather frequently, so obviously I'm interested in having better autonomy - even if that's at the expense of slightly worse performance when on battery power.
First, I use to set the CPU like this:
Code: Select all
/usr/bin/cpufreq-set -f 800000 -r Then, after some checks, I prepared this simple script that I launch when going into battery (taken from some web that I cannot recall now):
Code: Select all
echo 5 > /proc/sys/vm/laptop_mode
echo 1 > /sys/devices/system/cpu/sched_mc_power_savings
echo ondemand > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo 1500 > /proc/sys/vm/dirty_writeback_centisecs
for i in /sys/bus/usb/devices/*/power/autosuspend; do echo 1 > $i; done
echo min_power > /sys/class/scsi_host/host0/link_power_management_policy
echo min_power > /sys/class/scsi_host/host1/link_power_management_policy
I also found some recommendations such as passing the "pcie_aspm=force" (for the PCI Express) and "usbcore.autosuspend=1" options to the kernel. Or like using 'irqbalance' and adding that (init.d) to the boot level.
With all this, I get typical CPU temperatures of 55-60ºC, the fan always on (typ. level 3 over 7) - and the air temperature from the fan is indeed warm. And... the funny thing is that, in an 'idle' KDE (even with some applications open such as Chromium, Thunderbird or Eclipse), the CPU usage, even with this setting of 800MHz forced, is typ. below 10% (and most time <4-5%). Except, of course, when opening some other application or running intensive things (e.g. watching a YouTube full-screen it goes to 50%). I mean, there's nothing eating up the CPU, it's simply... hot, and that's it.
I don't know if it could be the nVidia being always on. How could I check the nVidia GPU usage?
The problem is that it seems that my X/KDE is not even detecting the nVidia Optimus! (it's just running on the Intel graphics - and OK, that's fine if that means more battery time). Even deactivating the nVidia from BIOS doesn't help.
"powertop -d" shows this (in KDE, just Kate+Konsole open, Wifi active, screen brightness around 60%, WiMAX+Bluetooth turned off by BIOS, also HyperThreading turned off but keeping both i7 cores active):
Code: Select all
PowerTOP 1.13 (C) 2007 - 2010 Intel Corporation
Collecting data for 15 seconds
Cn Avg residency
C0 (cpu running) ( 3.7%)
polling 0.0ms ( 0.0%)
C1 mwait 0.6ms ( 2.9%)
C2 mwait 0.7ms ( 0.4%)
C3 mwait 1.1ms ( 0.1%)
C4 mwait 7.6ms (92.9%)
P-states (frequencies)
2.81 Ghz 5.0%
2.00 Ghz 0.4%
1200 Mhz 0.5%
1000 Mhz 0.4%
800 Mhz 92.2%
Wakeups-from-idle per second : 172.5 interval: 15.0s
Power usage (ACPI estimate): 15.6W (3.1 hours)
Top causes for wakeups:
50.2% (244.4) [xhci_hcd:usb1, ehci_hcd:usb3, i915] <interrupt>
20.2% ( 98.3) [Rescheduling interrupts] <kernel IPI>
10.6% ( 51.6) [iwlwifi] <interrupt>
9.6% ( 46.9) [snd_hda_intel] <interrupt>
4.1% ( 20.1) knotify4
1.1% ( 5.1) [ahci, mmc0] <interrupt>
1.0% ( 4.9) kwin
0.8% ( 3.7) plasma-desktop
0.8% ( 3.7) X
0.2% ( 1.1) gam_server
0.2% ( 1.1) swapper/0
0.2% ( 1.0) krunner
0.2% ( 1.0) ifplugd
0.2% ( 0.9) kworker/0:3
0.1% ( 0.5) udisks-daemon
0.1% ( 0.5) kworker/u:4
0.1% ( 0.3) kded4
0.0% ( 0.2) konsole
0.0% ( 0.2) wpa_cli
0.0% ( 0.2) kactivitymanage
0.0% ( 0.2) init
0.0% ( 0.1) flush-8:0
0.0% ( 0.1) [Function call interrupts] <kernel IPI>
0.0% ( 0.1) wpa_supplicant
0.0% ( 0.1) irqbalance
0.0% ( 0.1) akonadi_control
0.0% ( 0.1) akonadiserver
Suggestion: increase the VM dirty writeback time from 5.00 to 15 seconds with:
echo 1500 > /proc/sys/vm/dirty_writeback_centisecs
This wakes the disk up less frequently for background VM activity
Suggestion: Enable the CONFIG_INOTIFY kernel configuration option.
This option allows programs to wait for changes in files and directories
instead of having to poll for these changes
Recent USB suspend statistics
Active Device name
0.0% USB device 4-1.4 : F5521gw (Lenovo)
0.0% USB device 3-1.6 : Integrated Camera (Chicony Electronics Co., Ltd.)
0.0% USB device 3-1.3 : Biometric Coprocessor (UPEK)
0.0% /sys/bus/usb/devices/4-1
0.0% /sys/bus/usb/devices/3-1
0.0% USB device usb4 : EHCI Host Controller (Linux 3.2.12-gentoo ehci_hcd)
0.0% USB device 1-1 : USB Receiver (Logitech)
0.0% USB device usb3 : EHCI Host Controller (Linux 3.2.12-gentoo ehci_hcd)
0.0% USB device usb2 : xHCI Host Controller (Linux 3.2.12-gentoo xhci_hcd)
0.0% USB device usb1 : xHCI Host Controller (Linux 3.2.12-gentoo xhci_hcd)
Runtime Device Power Management statistics
Active Device name
0.0% 0d:00.0 USB controller: NEC Corporation uPD720200 USB 3.0 Host Controller
100.0% 05:00.0 System peripheral: Ricoh Co Ltd Device e823
100.0% 03:00.0 Network controller: Intel Corporation Centrino Ultimate-N 6300
100.0% 00:1f.3 SMBus: Intel Corporation 6 Series/C200 Series Chipset Family SMBus Controller
100.0% 00:1f.2 SATA controller: Intel Corporation 6 Series/C200 Series Chipset Family 6 port SATA AHCI Controller
0.0% 00:1d.0 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family USB Enhanced Host Controller #1
100.0% 00:1c.4 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 5
100.0% 00:1c.3 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 4
100.0% 00:1c.1 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 2
100.0% 00:1c.0 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 1
100.0% 00:1b.0 Audio device: Intel Corporation 6 Series/C200 Series Chipset Family High Definition Audio Controller
0.0% 00:1a.0 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family USB Enhanced Host Controller #2
0.0% 00:19.0 Ethernet controller: Intel Corporation 82579LM Gigabit Network Connection
100.0% 00:16.3 Serial controller: Intel Corporation 6 Series/C200 Series Chipset Family KT Controller
100.0% 00:02.0 VGA compatible controller: Intel Corporation 2nd Generation Core Processor Family Integrated Graphics Controller
100.0% 00:00.0 Host bridge: Intel Corporation 2nd Generation Core Processor Family DRAM Controller
Devices without runtime PM
00:1f.0 ISA bridge: Intel Corporation QM67 Express Chipset Family LPC Controller
00:16.0 Communication controller: Intel Corporation 6 Series/C200 Series Chipset Family MEI Controller #1
Recent audio activity statistics
Active Device name
Recent SATA AHCI link activity statistics
Active Partial Slumber Device name
Many, many thanks in advance...




