Linux on the Lenovo ThinkPad R61i

[[TOC]]

I'm using Ubuntu 8.04 (Hardy Heron) on my Lenovo ThinkPad R61i. These are the hardware specific details of my installation.
Some of my problems are not listed here as they vanished with a kernel upgrade. Actually I use the vanilla 2.6.24(-17-generic) kernel.

==lcpsi==
00:00.0 Host bridge: Intel Corporation Mobile PM965/GM965/GL960 Memory Controller Hub (rev 0c)
00:02.0 VGA compatible controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 0c)
00:02.1 Display controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 0c)
00:1a.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #4 (rev 03)
00:1a.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #5 (rev 03)
00:1a.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #2 (rev 03)
00:1b.0 Audio device: Intel Corporation 82801H (ICH8 Family) HD Audio Controller (rev 03)
00:1c.0 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 1 (rev 03)
00:1c.1 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 2 (rev 03)
00:1c.2 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 3 (rev 03)
00:1c.3 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 4 (rev 03)
00:1c.4 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 5 (rev 03)
00:1d.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #1 (rev 03)
00:1d.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #2 (rev 03)
00:1d.2 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #3 (rev 03)
00:1d.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #1 (rev 03)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev f3)
00:1f.0 ISA bridge: Intel Corporation 82801HEM (ICH8M) LPC Interface Controller (rev 03)
00:1f.1 IDE interface: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) IDE Controller (rev 03)
00:1f.2 SATA controller: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) SATA AHCI Controller (rev 03)
00:1f.3 SMBus: Intel Corporation 82801H (ICH8 Family) SMBus Controller (rev 03)
03:00.0 Network controller: Intel Corporation PRO/Wireless 3945ABG Network Connection (rev 02)
04:00.0 Ethernet controller: Broadcom Corporation NetLink BCM5787M Gigabit Ethernet PCI Express (rev 02)
15:00.0 CardBus bridge: Ricoh Co Ltd RL5c476 II (rev ba)
15:00.1 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 04)
15:00.2 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 21)
15:00.3 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 11)
15:00.4 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 11)
15:00.5 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 11)

==Hard disk issues==
The disk does approx. 25 load cycles per minute. This could be too much. I guess this is related to a Linux/disk firmware [[53|bug]].

==Updateing the BIOS==
I had to update the BIOS prior installing Linux as a stand alone operating system because only the win32 update utility worked, the bootable FreeDOS CD-image failed to boot:

cdr101 not ready reading drive c.

==ACPI issues==
ACPI still remain an issue for Linux. The kernel code is made of spaghetti, full of legacy parts and crappy worksforme code.

=== Suspend, hibernate, resume===
The current ACPI code is a reason for all sorts of problems around [http://brainstorm.ubuntu.com/idea/94/ suspend, hibernate and resume], but luckily it works pretty stable for this model.

===Hotkeys===
All the hotkeys at the top work well. But the multimedia keys at the bottom (zoom,prev,play/pause,stop on space,left,down,right,up) do not work at all. They not even generate a kernel event, neither ACPI nor keyboard.

===Hotswap drivebay===
I don't have a second device, but the hotswap function obviously wouldn't work: ejecting the optical driver from the bay results in a kernel hang (no oops, no dump, just freeze). Not working at all, if no device is present at boot time, otherwise it should work.

===Docking station===
Couldn't test it, but the [http://ibm-acpi.sourceforge.net/ thinkpad_acpi] [http://ibm-acpi.sourceforge.net/README documentation] states that it should work, but only if a docking station is present at the boot time.

==Fingerprint reader==
Does not work. Lenovo replaced the TouchStrip fingerprint module (long used in ThinkPads by IBM) with one from UPEK. According to lsusb:
Manufacturer TouchStrip
Model Fingerprint Sensor
Bus usb
Type Vendor Specific Class
Id 147e
Info2 2016

The fingerprint reader libthinkfinger won't work! UPEK claims to have an [http://www.upek.com/solutions/pc_and_networking/sdks/linux/ driver], but it failed to build for me. It uses proprietary code, and requires to use a scarce authentication model.

==Trackpoint and touchpad==
Works fine. You need to add
Section "InputDevice"
Identifier "Synaptics Touchpad"
Driver "synaptics"
Option "SHMConfig" "on"
EndSection
to xorg.conf to be able to configure it's characteristics in more detail. I prefer gsynaptics to disable tap clicking and enable a horizontal scroll.

==Firewire==
Not tested.

==USB==
Fast and flawless.

==Gigabit LAN==
Fast and flawless.

==Bluetooth==
Works well. To turn it on/off separately from the wifi (that can be done by Fn+F5), I use this script mapped to the blue 'ThinkVantage' button on the top:
#!/bin/bash
cat /proc/acpi/ibm/bluetooth | awk '{ print $2 }' | while read line;
do
if [ $line == "enabled" ]; then
echo disable > /proc/acpi/ibm/bluetooth
else
echo enable > /proc/acpi/ibm/bluetooth
fi
break
done
See [[52|this]] post to get a 3G phone working as a broadband modem over wifi.

==Wifi==
It is surprisingly stable and reliable. Although the LED for wirless activity does not work.

==Video==

===Internal TFT===
Good image quality, stable open source driver. Ubuntu has a patch for the X.org driver to get hardware overlay for XVideo working with compiz enabled. Additional tweaks are required to get compiz working, although some effects are utterly slow. Use this in xorg.conf:
Section "Device"
Identifier "Configured Video Device"
Driver "intel"
Option "AccelMethod" "EXA"
Option "ExaNoComposite" "false"
Option "TexturedVideo" "false"
Option "MigrationHeuristic" "greedy"
EndSection
And add this to /etc/environment:
LIBXCB_ALLOW_SLOPPY_LOCK=1
INTEL_BATCH="1"

===External VGA===
A little more problematic. Compiz gets too slow to remain usable on two monitors. This can't be because of the Intel chip, as rendering a simple cube with textures can't require hardcore 3D acceleration.
Also GL screensavers result usually in a black monitor (no hang, just no console at all).
I had to extend xorg.conf to get an appropriate virtual screen to fit both the internal and external displays in.
Section "Screen"
Identifier "Default Screen"
Monitor "Configured Monitor"
DefaultDepth 24
SubSection "Display"
Depth 24
# no DRI above this
Virtual 2048 2048
EndSubSection
EndSection
xrandr works well for configuring the displays and managing the modes. The hotkey on the keyboard switches to clone mode. I prefer a more sophisticated control using [[67|this]] script.

===S-VIDEO out===
I don't know whether it is working or not, but it is not listed in xrandr.

==Cardreader==
Works flawless and out of the box.

==Sound==
Sound quality is good until PCM volume is below 75%. The internal microphone does not work at all. All the external microphones I used produced a horrible recording quality. Some voice recording programs failed to work or recorded silence. This is a big issue for me.

==HDAPS==
[http://www.thinkwiki.org/wiki/HDAPS HDAPS] should protect the hard disk in case of falling/dropping/hitting the laptop by parking the heads in case of unusual acceleration patterns. That's right, ThinkPads ship with an acceleration meter.

With the newest kernel the measuring works. hdaps-gl displays the orientation of the laptop in space. I submitted a kernel patch (for drivers/hwmon/hdaps.c) to lkml to reverse an axis:
@@ -515,6 +515,7 @@ static struct dmi_system_id __initdata h
HDAPS_DMI_MATCH_NORMAL("IBM", "ThinkPad R50"),
HDAPS_DMI_MATCH_NORMAL("IBM", "ThinkPad R51"),
HDAPS_DMI_MATCH_NORMAL("IBM", "ThinkPad R52"),
+ HDAPS_DMI_MATCH_INVERT("LENOVO", "ThinkPad R61i"),
HDAPS_DMI_MATCH_INVERT("IBM", "ThinkPad T41p"),
HDAPS_DMI_MATCH_NORMAL("IBM", "ThinkPad T41"),
HDAPS_DMI_MATCH_INVERT("IBM", "ThinkPad T42p"),
Or you can simply add invert=1 to the module parameters of hdaps_ec.

Please note, that protection will not work! It [http://www.thinkwiki.org/wiki/HDAPS#Kernel_patch seems] that the kernel does not apply any protection, it just makes the measured valued available to userspace. More worse, there is no userspace or kernel tool available to do the parking (yet).

==Battery==
According to powertop there are 100-300 wakeups-from-idle per seconds. This seems very high. Power usage is between 15 and 22 watts. On batteries I enabled laptop-mode, dim the backlight and if not needed, I use the RF kill switch.
# cat /proc/acpi/battery/BAT0/info
present: yes
design capacity: 56160 mWh
last full capacity: 53240 mWh
battery technology: rechargeable
design voltage: 10800 mV
design capacity warning: 2662 mWh
design capacity low: 200 mWh
capacity granularity 1: 1 mWh
capacity granularity 2: 1 mWh
model number: 42T4504
serial number: 42054
battery type: LION
OEM info: SANYO
After half a year of heavy usage I have the above capacity and a runtime of 2,5-3 hours on batteries.

==Modem==
Who cares?

==PCMCIA, CardBus==
Not tested.

==Kernel options==
Do NOT add irqpoll to the kernel options as it will cause a severe nondeterministic behaviour.

linux-laptop.net


Linux On Laptops

--
GaB

Happy to find someone using

Happy to find someone using Hardy on a R61i too.
In term of functionality, Having internal microphone not working is a big issue for me. Fingerprint reader is less of an issue issue.
I have some wifi issues at boot or resume: It not always connects but it does it usually takes 1 or 2 minutes to connect.
I feel slightly frustrated that the HDAPS is not supported by Ubuntu (measuring without parking).

The battery autonomy is also lower than with XP. I'm unsure if this is related but the Fan seems to be always on whatever if I'm on battery or on AC power.

I'm unsure if I'm affected by the disk load cycle problem. I'll appreciate your experience in determining if I'm or not.

mic+hd

Far more worse for me, I did not managed to get the external mic working: I always have a distorted and jerky noise as input (Ubuntu bug 69306). (For a short period of time, selecting "HDA Intel (hw:intel,0)" as "sound in" device worked fine for some apps, but not now.)

Did you managed to get it working properly?

For the disk load cycle issue my guess is, that we are partially affected: when I installed Ubuntu 8.04 alpha5, there were approx. 20-22 load cycles a minute. Up to 15 may be fully OK, but 22 is still in a reasonable range. Also some manufacturers are having higher values by intent so the disks are designed to handle more load cycles and save power this way. I'm not sure whether disks in this model are of this kind, but I would expect it from a ThinkPad. Regardless I apply hdparm -B 254 .

--
GaB

Yes, the "internal mic"

Yes, the "internal mic" always "on" regardless there is application to use it or not is a nuisance as at times some high pitch tone can be heard (those sound when you put a mic near a speaker).

I think Lenovo has to provide a package of Thinkpad drivers on linux/Ubuntu platform is very important. Let's write this to Lenovo so that they knows there are great demand out there.

Wifi

I am running 8.10 on my R61i and I am really happy with the stability and performance, all seems to work well. I still have XP on it, in a dual boot configuration, and the wireless connectivity under XP never seems to work well, even with the latest XP service pack and patches, and the latest Lenovo driver. Under Ubuntu this is rock solid, though. Weird. Luckily I only need XP occasionally, and I have an ethernet cable close at hand for those circumstances.

Fingerprint reader is less of

Fingerprint reader is less of an issue issue.
I have some wifi issues at boot or resume: It not always connects but it does it usually takes 1 or 2 minutes to connect.
I feel slightly frustrated that the HDAPS is not supported by Ubuntu (measuring without parking
blog commenting service

nice post

I still have XP on it, in a dual boot configuration, and the wireless connectivity under XP never seems to work well, even with the latest XP service pack and patches, and the latest Lenovo driver. Under Ubuntu this is rock solid, though. Weird. Luckily I only need XP occasionally

Thanks

Much needed info thank you. Fights