Lenovo Thinkpad T61
From Gentoo Linux Wiki
| FIXME: There is plenty to do. Have a look at Things to be done on the discussion page. |
Contents |
[edit] Hardware status
| Device | Works? | Note |
| CPU | Yes | See this HowTo |
| ACPI | Yes | Buttons: sleep (Fn-F4), power (working both on laptop and dockingstation), lid. AC Connector: plug, unplug. |
| DVD-Recorder | Yes | read/write tested. (write tested with app-cdr/dvd+rw-tools-7.0 and app-cdr/cdrtools-2.01.01_alpha25) |
| UltraNav (psmouse) | Yes | |
| USB (uhci_hcd, ehci_hcd) | Yes | followed Gentoo USB Guide. Tested with with card-reader, mouse, hp scanner, external hdd, flash-stick. |
| Wired ethernet (e1000e) | Yes | also works with e1000, but as we have the pcie one... |
| Wireless LAN (iwl3945 or iwl4965) | Yes | See this guide |
| Wireless WAN (Sierra MC8775 UMTS/HSDPA) | Yes | Works with the "sierra" driver from kernel 2.6.24 |
| X11 | Yes | x11-drivers/nvidia-drivers-173.14.09: working x11-drivers/xf86-video-i810-2.1.1: working |
| External monitor | Yes | x11-drivers/nvidia-drivers-173.14.09: Tested with Benq V772 CRT. |
| vesafb | Yes | working with size 1440x900 and depth 32 with both intel and nvidia using a vga=868 kernel parameter. Append video=... parameter instead for uvesafb (see (u)vesafb). |
| Sound (snd_hda_intel) | Yes | Good support since 2.6.24 Don't forget to press the physical Vol-up button to remove the hardware mute! |
| Multimedia keys | Yes | See Multimedia keys section. |
| Fn-Fx key combinations (thinkpad_acpi) | Partial | See hotkeys (Fn-Fx key combinations) section. |
| Bluetooth | Yes | followed Gentoo Bluetooth Guide: pairing and file transfer worked with Nokia 9300, Siemens SXG75 and SonyEricsson P1i. |
| Firewire (ieee1394) | Yes | Included the standard kernel modules. Testing with an external hard drive |
| PCMCIA (yenta_socket) | Yes | Kernel modules needed. Tested with a SoundBlaster Audigy PCMCIA |
| SMARTCARD | Untested | |
| IBM Harddisk Protection System | Yes | See hdaps section. |
| fingerprint reader | Yes | Works with sys-auth/thinkfinger. Configuration tips see ThinkWiki. |
| Internal modem | Untested | |
| Media card reader | Yes | |
| Serial port | Yes | Thinkpad Serial/Parallel Port adapter #40Y8121 works out of the box |
| Webcam | Untested | Have a look at fgo: T61 internal USB-Camera |
[edit] Introduction
[edit] Packages that will need unmasking by keyword
# ## set your ~arch as needed! # # package.keywords: media-video/nvidia-settings ~amd64 net-wireless/wireless-tools ~amd64 sys-apps/tuxonice-userui ~amd64 sys-apps/vbetool ~amd64 sys-kernel/gentoo-sources ~amd64 sys-kernel/git-sources ~amd64 sys-kernel/zen-sources ~amd64 sys-kernel/tuxonice-sources ~amd64 x11-drivers/nvidia-drivers ~amd64 x11-drivers/xf86-video-nv ~amd64 #Intel graphics =media-libs/mesa-6.5.3* ~x86 x11-drivers/xf86-video-i810 ~x86
[edit] Hardware
Hardware specs may vary. These are the specs for model 7663-W5T (german keyboard layout):
Processor Intel Core 2 Duo Processor T7500 with 2,20 GHz, 4 MB L2 Cache Front Side Bus 800 MHz RAM 1 GB 667 MHz DDR2 Harddisk 5400 U/min; 120 GB Harddisk SATA with Active Protection System Optical DVD Multiburner Dual Layer (DVD +/-) in UltraBay Slim Display TFT Display; 14,1 Zoll (35,8 cm); 1440x900 GFX 128 MB DDR RAM; nVIDIA Quadro NVS 140M Communication 10/100/1000 LAN, Intel Mini PCI PRO/Wireless 3945ABG Lan, 56K Int. Modem, Bluetooth Sound System Intel High Definition Audio Input Devices IBM UltraNav (Touchpad+TrackPoint) Connectors 3x USB 2.0-Ports, VGA, Headphone, ext. microphone, RJ-11, RJ-45, Firewire (IEEE 1394) PC Card Extensions 1 x PCMCIA Typ I oder II und 1 x SMARTCARD Dimensions (WxDxH) 335,5 x 237 x 27,6 mm
[edit] Configuration detail
[edit] (u)vesafb
[edit] 1440x900 Resolution
| FIXME: Could someone please point out what causes these differences? |
Using the vesafb driver, the following kernel parameter is required:
- Intel/Nvidia cards: vga=868 (previously reported vga=869 is invalid. 869 isn't even a valid mode number.)
Starting with gentoo-sources-2.6.23 (And will probably be mainline in 2.6.24) you might want to choose uvesafb. The required kernel parameter is: video=uvesafb:1440x900-32,mtrr:3,ywrap. See Links section for references.
[edit] eyecandy
gensplash and qingy will work flawlessly, however do not forget to edit /etc/dircectfbrc for qingy to work:
| File: /etc/directfbrc |
mode=1440x900-77 depth=32 |
[edit] Power Management
We recommend using the commands hibernate and hibernate-ram from sys-power/hibernate-script. Edit the files in /etc/hibernate to your needs.
| Function | Works? | Note |
| suspend to disk (sys-kernel/tuxonice-sources) | Partial | Needs testing. So far few problems from X and no from console. |
| suspend to disk (standard kernel suspend) | Partial | Needs testing. So far few problems from X and no from console. |
| Suspend to ram | Yes | nvs 140@X11: okay nvs 140@Console: okay using >=x11-drivers/nvidia-drivers-173.14.05 |
| dynticks (using zen-sources) | Partial | If you call a minimum of ~20 wakeups per sec a success, then: yes its working! (With either textconsole or X) |
[edit] Suspend to disk
The following was tested on amd64. Working suspend to disk with x11-drivers/nvidia-drivers using sys-power/hibernate-script hibernate command. remove nvidia from /etc/hibernate/blacklisted-modules. Driver / software versions : tuxonice-sources-2.6.23-r5, nvidia-drivers-169.07 (using custom overlay) and sys-power/hibernate-script-1.97-r4. See nalldrin's config files (or tante's kernel config if you want to use dm-crypt for drive encryption) for full files relevant info.
[edit] Suspend to RAM
nvs 140@X11: resumes (requires more testing). Using vbetool is not required. Unloading the following modules gives less dmesg-errors (sorry, not sure which on is the culprit): thinkpad_acpi snd_hda_intel parport_pc sr_mod sg button tun e1000. vga=0 and vga=869 both work.
nvs 140@Console: Suspending to ram from console has been tested to work with uvesafb framebuffer on a Thinkpad with nvidia card. This was possible with x11-drivers/nvidia-drivers-173.14.05.
Also have a look at tuxonice section@discussions page
Intel graphics may need to save and restore the vbemode with vbetool.
[edit] dynticks
Dynticks can only be used with x86 architecture at the moment - amd64 might get supported in the future but still has some issues.
A non-dynticks kernel had 1500 wakups minimum, a kernel with dynticks comes down to 20-40. Have in mind that there are some real "interrupter" both in user-software and drivers. Java and the nvidia closed-source drivers are two candidates. If in textmode only ehci_work is top with 10 wakeups per sec.
[edit] xorg.conf
[edit] video drivers
- x11-drivers/nvidia-drivers: No problems with glx and multihead.
- Eye-candy (compiz-fusion) lags hard because of nvidia's powermizer (it seems that it can be disabled, have a look at this)
- Brightness control is possible as of version 169.07.
- One has to do eselect opengl set nvidia first to ensure that the correct GLX module is loaded.
- Eye-candy (compiz-fusion) lags hard because of nvidia's powermizer (it seems that it can be disabled, have a look at this)
- x11-drivers/xf86-video-nv: amd64 does not work due to unknown card. ~amd64 works (make sure proprietary nvidia module is not loaded).
- x11-drivers/xf86-video-vesa: No problems resuming from sleep/hibernation. Does not run in 1440x900.
- x11-drivers/xf86-video-i810: See this guide.
[edit] Multimedia keys
Working keys : volume (up/down), back, forward, audio-play, audio-stop, audio-next, audio-noprevious.
| File: ~/.Xmodmap |
keycode 234 = XF86Back keycode 233 = XF86Forward keycode 144 = XF86AudioPrev keycode 164 = XF86AudioStop keycode 162 = XF86AudioPlay keycode 153 = XF86AudioNext keycode 160 = XF86AudioMute keycode 174 = XF86AudioLowerVolume keycode 176 = XF86AudioRaiseVolume |
Follow Assigning keys to special functions @ HOWTO Use Multimedia Keys to make these keys available in your favourite WM or DE.
[edit] Dockingstation
Using the Thinkpad Advanced Mini Dock seems to work without problems so far. A short overview:
| Device | Works? | Note |
| USB (uhci_hcd, ehci_hcd) | Yes | All four ports working with several USB-devices. |
| RJ-45 (e1000) | Yes | |
| RJ-11 | Untested | |
| DVI-Out | Yes | Using it permanently with Benq FP783 |
| VGA-Out | Yes | Tested with Benq V772 CRT |
| Sound (snd_hda_intel) | Partial | speaker-out is working with kamikaze-sources, micro-in is working with mm-sources, internal-micro is working with mm-sources, S/PDIF untestd |
| PS/2 | Yes | Using a standard keyboard with it. |
| RS-232 (8250) | Untested | build the kernel-modules but did not test it, load without problems. |
| Parallel-Port | Yes | HP Deskjet 816c prints. |
[edit] Docking / Undocking
| FIXME: Compiled with either CONFIG_ACPI_DOCK or CONFIG_THINKPAD_ACPI. thinkpad_acpi says it is legacy. Pressing the undock button while using CONFIG_ACPI_DOCK will cause the lock-LED on dockingstation turn off, but did not try to take the Thinkpad away from station so far.)
Alvar: With CONFIG_ACPI_DOCK docking and undocking works like a charm. |
[edit] Howto ...
Some of these links lead to old parts of this article that had to be moved due to oversizing:
- ... auto toggle wired/wireless on cable connect
- ... start vpnc on a certain ESSID
- ... toggle synaptics touchpad
- ... customize Trackpoint (scrolling)
- ... setup TwinView and Xinerama
- ... Thinkpad Fn-Keys
[edit] thinkpad_acpi
This is the new name for the formerly called ibm_acpi kernel modules. It can now be found at Device Drivers ---> Misc Devices ---> ThinkPad ACPI Laptop Extras
| Device | Works? | Note |
| Bay | No | thinkpad_acpi with debug=1 parameter reports thinkpad_acpi: drv_acpi_handle_init: ACPI handle for bay not found and thinkpad_acpi: bay_init: bay 1: status not supported, eject not supported; bay 2: status not supported, eject not supported. However, the generic ACPI bay handler will work, if you patch it to generate ACPI events. Alternatively you can add the T61's bay's ACPI path (\_SB_.PCI0.IDE0.PRIM.MSTR) to thinkpad_acpi |
| Bluetooth | Yes | Echoing enable or disable does toggle the device status. The kernel will load bluetooth modules if compiled. |
| Fan | Untested | |
| Hotkey | Partial | ThinkVantage-Button and Fn-F11 do never trigger an event. See Multimedia keys with thinkpad_acpi for more info. |
| Temperatures | Partial | Version 0.14 loaded with modprobe thinkpad_acpi experimental=1 debug=1 will report 16 temperatures. Only 8 are usable. I could not find a source to identify them all. |
| Video | Partial | nvidia-drivers: brightness control works as of version 169.07. With intel graphics the brightness control works, but nothing else does. |
| Volume | Partial | See below. |
| ThinkLight | Yes | Hard wired, thinkpad_acpi reports status at /proc/acpi/ibm/light:status |
| Brightness Control | Yes | x11-drivers/nvidia-drivers now working too. See below. |
[edit] Volume control
Mute does silence the sound but pressing Mute a second time does not unmute. Vol-up or vol-down have to be pressed to unmute. Volume up/down buttons generate keyevents so volume can be controlled via a seperate program by using ~/.Xmodmap and ~/.xbindkeysrc (see Multimedia keys). Interfacing /proc/acpi/ibm/volume via
echo up > /proc/acpi/ibm/volume has no effect; you must use echo up >> /proc/acpi/ibm/volume
KDE's default configuration does not recognize the volume buttons correctly, as it tries to adjust the “master” output. Instead, you have to right-click on the PCM output in the main window of kmix and set up the volume keys as shortcut keys controlling the volume of the PCM output.
[edit] Brightness control
Seems hard wired. Reports status at /proc/acpi/ibm/brightness:level. Does not work under Xorg with x11-drivers/nvidia-drivers <169.07. The latest version works okay.
Had success with x11-drivers/xf86-video-vesa and x11-drivers/xf86-video-vesa.
No Problems with x11-drivers/xf86-video-i810 and intel graphics.
[edit] Fan control
To control the cpu fan, you should compile the thinkpad_acpi of your kernel as a module and load it with fan_control=1
# modprobe thinkpad_acpi fan_control=1
Then install the package lm_sensors:
# emerge -av lm_sensors
Then you can run the script pwmconfig
# pwmconfig
which will generate a config file /etc/fancontrol interactively. Here is the foncontrol config file of my T61-8889-IHC:
INTERVAL=120 FCTEMPS=hwmon2/device/pwm1=hwmon2/device/temp1_input FCFANS=hwmon2/device/pwm1=hwmon2/device/fan1_input MINTEMP=hwmon2/device/pwm1=50 MAXTEMP=hwmon2/device/pwm1=70 MINSTART=hwmon2/device/pwm1=128 MINSTOP=hwmon2/device/pwm1=128 MINPWM=hwmon2/device/pwm1=0 MAXPWM=hwmon2/device/pwm1=255
Refer to the manpage of fancontrol for the detailed descriptions of these parameters. Finally, activate the fancontrol daemon:
# /etc/init.d/fancontrol start
Now your CPU fan will stop boring you if the temperature of your CPU is below 50°C.
[edit] hotkeys (Fn-Fx combinations)
Without thinkpad-acpi only Fn-F4 will generate button/sleep event. All other Fn-Fx combinations are inactive. Use thinkpad-acpi to enable the rest of the Fn-Fx key combinations.
Brightness controls (Alt F10,F11) are hard wired, but only have effect while in text-mode, or using xorg-vesa- or xorg-nv-driver. x11-drivers/nvidia-drivers-169.07 supports xorg brightness control, too.
Sleep (F4) button registers in acpi.
Mute is hardwired as well but no effect despite change in /proc/acpi/ibm/volume:mute so far recognized.
[edit] Usage of acpid
There are a lot of solutions for acpid and thinkpad_acpi hotkey feature on the web mainly using files in /etc/acpi/events/ and /etc/acpi/actions/. For example you can download the old source package from ibm-acpis sourceforge download page containing such example files (do not choose the patches, you need one of the old *.tar.gz. Another way is to tweak /etc/acpi/default.sh a bit:
| File: /etc/acpi/default.sh |
#!/bin/sh
# Default acpi script that takes an entry for all actions
set $*
ev_type=`echo "$1" | cut -d/ -f1`
# We have to take special care for events send by ibm/hotkey:
if [ "$ev_type" = "ibm" ]; then
ev_type=`echo "$1" | cut -d/ -f1`
event=`echo "$1" | cut -d/ -f2`
key="$2"\ "$3"\ "$4"
else
# Take care about the way events are reported
ev_type=`echo "$1" | cut -d/ -f1`
if [ "$ev_type" = "$1" ]; then
event="$2";
else
event=`echo "$1" | cut -d/ -f2`
fi
fi
case "$ev_type" in
button)
case "$event" in
power)
logger "acpid: power button pressed; starting shutdown"
# logger "acpid: received a shutdown request"
/sbin/init 0
break
;;
sleep)
logger "acpid: sleep button pressed; initiating hibernate-ram"
# logger "acpid: received hibernate request"
/usr/sbin/hibernate-ram
;;
lid)
logger "acpid: lid event"
;;
*)
logger "acpid: action $2 is not defined"
;;
esac
;;
# BEGIN customization for ibm/hotkey:
ibm)
case "$event" in
hotkey)
case "$key" in
"HKEY 00000080 00001002")
logger "acpid: lock button (Fn+F2) pressed"
# Lock the desktop,- only works for display :0
x_user=`who | sed -ne "s/^\([^[:space:]]*\)[[:space:]]*:0.*/\1/p"`
if [ -n $x_user ]; then
# Use a script or use any desktop lock command
export DISPLAY=":0.0"
su $x_user -c /usr/local/bin/lock_desktop.sh
fi
;;
"HKEY 00000080 00001003")
logger "acpid: battery button (Fn+F3) pressed; switching display off"
/usr/local/bin/thinkpad_acpi_battery.sh &> /dev/null
;;
"HKEY 00000080 00001004")
logger "acpid: sleep button (Fn+F4) pressed; initiating hibernate-ram"
/usr/sbin/hibernate-ram
;;
"HKEY 00000080 00001005")
logger "acpid: bluetooth button (Fn+F5) pressed; toggling bluetooth"
/usr/local/bin/thinkpad_acpi_bluetooth.sh &> /dev/null
;;
"HKEY 00000080 00001007")
logger "acpid: screen toggle button (Fn+F7) pressed"
;;
"HKEY 00000080 00001008")
logger "acpid: UltraNav toggle button (Fn+F8) pressed; toggling touchpad status"
/usr/local/bin/thinkpad_acpi_touchpad.sh &> /dev/null
;;
"HKEY 00000080 00001009")
logger "acpid: eject button (Fn+F9) pressed"
/usr/local/bin/thinkpad_acpi_dock-control.sh &> /dev/null
;;
"HKEY 00000080 0000100c")
logger "acpid: hibernate button (Fn+F12) pressed; initiating hibernate"
/usr/sbin/hibernate
;;
"HKEY 00000080 00007000")
logger "acpid: radio switch action; toggling all wireless devices"
/usr/local/bin/thinkpad_acpi_bluetooth.sh &> /dev/null
/usr/local/bin/thinkpad_acpi_wlan.sh &> /dev/null
;;
"HKEY 00000080 00001010")
logger "acpid: increase brightness"
echo up > /proc/acpi/ibm/brightness
break
;;
"HKEY 00000080 00005010")
logger "apcid: decrease brightness"
echo down > /proc/acpi/ibm/brightness
break
;;
"HKEY 00000080 00005001")
# This is the lid CLOSE event
# as of now it is already handled above
;;
"HKEY 00000080 00005002")
# This is the lid OPEN event
# as of now it is already handled above
;;
*)
logger "acpid: $ev_type/$event $key is not defined"
;;
esac
;;
dock)
case "$key" in
"GDCK 00000003 00000001")
logger "acpid: Dock eject request"
;;
"GDCK 00000003 00000002")
logger "acpid: laptop was undocked"
;;
"GDCK 00000000 00000003")
logger "acpid: laptop was docked"
;;
*)
logger "acpid: $ev_typ $event event $key is not defined"
;;
esac
;;
bay)
case "$key" in
"MSTR 00000003 00000000")
logger "acpid: got ultrabay eject request"
;;
"MSTR 00000001 00000000")
logger "acpid: ultrabay eject lever inserted"
;;
esac
;;
esac
;;
*)
logger "ACPI group $1 / action $2 is not defined"
;;
esac
|
[edit] Fn-F7 Video output toggle
/proc/acpi/ibm/video reports status: supported but any changes have no effect.
[edit] other buttons
See
[edit] Wireless switch on the front beneath firewire
Switch state is reported at /sys/devices/platform/thinkpad_acpi/hotkey_radio_sw
| File: /usr/local/bin/thinkpad_acpi_wlan.sh |
#!/bin/bash if(cat /sys/devices/platform/thinkpad_acpi/hotkey_radio_sw | grep -e "0" > /dev/null); then if(/etc/init.d/net.wlan0 status | grep -e "started" > /dev/null) ; then echo "Stopping net.wlan0" /etc/init.d/net.wlan0 stop --quiet modprobe -r iwl3945 fi fi if(cat /sys/devices/platform/thinkpad_acpi/hotkey_radio_sw | grep -e "1" > /dev/null); then if(/etc/init.d/net.wlan0 status | grep -e "stopped" > /dev/null) ; then echo "Starting net.wlan0" # Make sure all needed modules are loaded: if(/bin/lsmod | grep -e "iwl3945" > /dev/null) ; then echo "Module iwl3945 already loaded" > /dev/null else # echo "Loading module iwl3945" modprobe iwl3945 fi /etc/init.d/net.wlan0 start --quiet fi fi |
To make /etc/init.d/net.wlan0 honour the switch state add this to /etc/conf.d/net
| Code: excerpt from /etc/conf.d/net |
preup() {
if [[ ${IFACE} == "wlan0" ]]; then
if(cat /sys/devices/platform/thinkpad_acpi/hotkey_radio_sw | grep -e "0" > /dev/null); then
ewarn "Thinkpad wireless switch is disabled"
return 1
fi
fi
return 0
}
|
[edit] tp_smapi: Harddisk Active Protection System (hdaps)
The hdaps kernel module produced by tp_smapi will work, but you need to pass the invert=1 parameter when loading the module or all input will be inverted. Stopping the disk works, but requires a kernel patch from the ones listed on ThinkWiki. Have a look at Discussions Page.
[edit] Kernel Config
Thinkpad T61 should work with any kernel greater 2.6.22.
| Linux Kernel Configuration: Kernel essentials |
# For proper booting you should at least enable the following in kernel.
Bus options (PCI etc.) --->
--- PCI support
[*] PCI Express support
Device Drivers --->
<*> Serial ATA (prod) and Parallel ATA (experimental) drivers --->
<*> AHCI SATA support
<*> Intel ESB, ICH, PIIX3, PIIX4 PATA/SATA support
<*> SCSI device supplort ---->
<*> SCSI disk support
<*> SCSI CDROM support
<*> SCSI generic support
# don't forget to make the kernel use the power of two hearts
Processor type and features --->
[*] Symmetric multi-processing support
[*] Multi-core scheduler support
|
[edit] Pre-Installation Notes
[edit] livecd-2007.0-amd64 / ahci / compat
The live-cd may hang at:
Loading modules ... scanning for ahci...
There does not seem to be any suitable kernel parameter to boot the livecd with which solves the problem. Switch Config/Serial-ATA from <ahci> mode to <compatibility> mode in BIOS. After installing, switch back to <ahci> mode.
[edit] Problems and Solutions
[edit] x86: nvidia-drivers not working and irq complaints
On T61s with old BIOS-Version (1.09 (7LET39WW) 2007-05-14 for me) one might get an "irq xx: nobody cared" error (example output) and nvidia-module complains about not receiving interrupts (example output). All workarounds seem to make another HW-Part unusable.
The solution is a BIOS update (most easy via ThinkVantage SystemUpdate) to the newest version (1.22 (7LET52WW) 2007-08-27 at the moment).
[edit] Links
- Guide for Debian Etch on Thinkpad T61 with huge listings of system specs
- fgo: Setup guide Thinkpad T61 with X3100 graphic chip
- Guide for the predecessor with help for CDMA card and Harddisk protection
- nvidia xorg.conf options
- Phoronix on NVS 140M
- nvidia announcing improvements regarding suspend/resume
- opensuse on suspend
- Rafael J. Wysocki's annual Suspend and hibernation status report (2007)
- This guide is listed at the TuxMobil Linux laptop and notebook installation survey (IBM/Lenovo).
References:
