Fedora 16 on TP X220

Fedora 16 on TP X220

I’ve recently bought a Lenovo (IBM) Thinkpad X220 (Sandy Bridge i7) and installed Fedora 16 onto it. I’ve used an encrypted (LUKS) LVM containing my root, swap and data partitions which I’m very satisfied with. In this post, I’ll gather things that might be of your interest for this hardware-software configuration.

  1. Update the BIOS!
  2. Power management: double your idle battery life with four kernel parameters
  3. Power management: use thinkfan for noise and wattage reduction
  4. Power management: finally get 6-9 h with laptop-mode-tools
  5. Make sensible use of the ThinkLight

Update the BIOS!

Consult http://support.lenovo.com/ for BIOS updates. This simple step lets you avoid a lot of potential problems, e. g. the infamous CPU throttling.

Power management: double your idle battery life with four kernel parameters

This had an extremely positive impact on battery life on my Sandy Bridge i7 (the X220 is using an integrated Intel GPU) with 3.2 and 3.3 kernels; I haven’t noticed any negative side effects. Just add the following four parameters to your /etc/default/grub under GRUB_CMDLINE_LINUX="...":

i915.i915_enable_rc6=1 i915.i915_enable_fbc=1 i915.lvds_downclock=1 pcie_aspm=force

This line looks like this in my Fedora:

GRUB_CMDLINE_LINUX="rd.luks.uuid=luks-xxxxxxxxxxxxxxxx rd.md=0 rd.dm=0 rd.lvm.lv=vg_on/lv_root quiet SYSFONT=latarcyrheb-sun16 rhgb rd.lvm.lv=vg_on/lv_swap  KEYTABLE=pl2 LANG=en_US.UTF-8 i915.i915_enable_rc6=1 i915.i915_enable_fbc=1 i915.lvds_downclock=1 pcie_aspm=force"

To generate a new /boot/grub2/grub.cfg, just issue

sudo grub2-mkconfig -o /boot/grub2/grub.cfg

Power management: use thinkfan for noise and wattage reduction

thinkfan is a nice little tool which lets you both keep your ThinkPad quiet and save power. Install it in your system and adjust /etc/thinkfan.conf to fit your needs. An example config for the X220 could be:

sensor /sys/devices/platform/coretemp.0/temp1_input
fan /proc/acpi/ibm/fan
{ "level 0"  # the fan level
    (0)      # LOWER temp limit
    (64)     # UPPER temp limit
}
{ "level 1"
    (62)
    (66)
}
{ "level 2"
    (64)
    (68)
}
{ "level 3"
    (66)
    (70)
}
{ "level 4"
    (68)
    (72)
}
{ "level 5"
    (70)
    (74)
}
{ "level 6"
    (72)
    (76)
}
{ "level 7"
    (74)
    (78)
}
{ "level disengaged"
    (76)
    (9999)
}

However, you should keep in mind that tinkering with fan speeds is hazardous; if the software fails to start the fan on time, you could burn your CPU. Also, this particular config is quite permissive, as it starts the fan only when the CPU reaches 64°C, which probably shortens the life span of the notebook noticeably.

Power management: finally get 6-9 h with laptop-mode-tools

Use laptop-mode-tools for — after applying all previously mentioned measures — good 6 hours of regular operation or even 9 hours of very power-conscious operation while on battery power. I used the newest version from http://samwel.tk/laptop_mode/, manually adjusting all settings from /etc/laptop-mode/ to fit my needs. I’m using the stock 7200 RPM 320 GB HDD.

I also recommend apending the line

rfkill block bluetooth

to /etc/rc.d/rc.local unless you’re using Bluetooth very often. Should you need Bluetooth, you can simply enable it using the regular GUI.

Make sensible use of the ThinkLight

I’m using a plugin called Blinklight for Pidgin (see http://www.joachim-breitner.de/blog/archives/369-pidgin-blinklight-goes-subliminal.html and http://darcs.nomeata.de/pidgin-blinklight.upstream/). It flashes the ThinkLight with a frequency generated from the contact’s name on receiving a new instant message. I had to append the line

chmod a+w /proc/acpi/ibm/light

to /etc/rc.d/rc.local to make it work. I’m looking forward to seeing (or, potentially, coding myself) an equivalent plugin for Thunderbird.

Visit http://www.thinkwiki.org/wiki/ThinkLight for more information.

, ,

One response to “Fedora 16 on TP X220”

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.