Installation notes for Debian (SID) on Acer TravelMate 654LCi

Last modified: 2006-01-14

Please visit TuxMobil: Linux On Mobile Computers and Linux on Laptops for loads of information on this topic.

Contents

Notes and News

Base Install

I have not tested installing with the current sarge installer, but I think there is no magic necessary.

For woody: Booting with bf2.4 kernel, using parted to delete the second and third partition, resize the first windows partition, make new partitions for linux (swap and /).

Install debian/woody base system from CDs.

Copy bcm4400-source from debian-sid via floppy to laptop.

Install kernel-headers-2.4.18-bf24

build modules, insmod, have network, yeahhh copy module into /lib/modules/2.4.18.../kernel/drivers/net add a line bcm4400 to /etc/modules (later on I will build my own kernel, later ...)

copy apt/sources.list from my sid box

apt-get update && apt-get dist-upgrade

build my own kernel (2.4.22-preX-disY with ACPI support included) this kernel contains b44 module for the network card, but it is not really working. (see notes at bottom)

Hardware Overview

Here is the output of lspci and the /proc/cpuinfo. Booting gives me the following output for kernel 2.6: dmesg-2.6.log and for kernel 2.4: dmesg-2.4.log.

In the following table I list the config options for kernel 2.4 and kernel 2.6, please see the relevant config files for details!

A simple working in the last column means that with my current kernel 2.6.15-mm3 I don't need anything special, no external modules.
Component Module/config options comments
CPU Mobile Intel(R) Pentium(R) 4 - M CPU 2.20GHz working
Audio i810-audio, CONFIG_SOUND_ICH, CONFIG_SND_INTEL8X0 working
USB usb-uhci, ehci-hcd, CONFIG_USB_UHCI(_HCD), CONFIG_USB_EHCI_HCD working
IEEE1394 (FireWire) ohci1394, CONFIG_IEEE1394_OHCI1394 working
AGPGART intel agpgart, CONFIG_AGP, CONFIG_AGP_INTEL working
PCMCIA yenta_socket, CONFIG_PCMCIA, CONFIG_CARDBUS, CONFIG_I82365 working, not tested with devices
NIC b44: CONFIG_B44 working
WLAN hostap: CONFIG_HOSTAP* working
Graphic Radeon 7500M radeon, CONFIG_DRM, CONFIG_DRM_RADEON working
SD Card Reader usb device, usb-storage, CONFIG_SCSI, CONFIG_SCSI_SD, CONFIG_USB_STORAGE working
CD Burner kernel 2.4:ide-scsi emulation, CONFIG_BLK_DEV_IDESCSI, CONFIG_SCSI_SG,
kernel 2.6: direct ide, no emulation necessary
working
IDE Intel PIIX chipsets, CONFIG_BLK_DEV_PIIX, CONFIG_BLK_DEV_IDEDMA_PCI, CONFIG_IDEDMA_PCI_AUTO, CONFIG_BLK_DEV_IDEDMA working
Synaptics Touchpad working
Modem CONFIG_SND_INTEL8X0M working
IRDA nsc ircc controller, CONFIG_NSC_FIR, CONFIG_IRDA* working
SmartCard Reader O2Micro not working, contacted developer
ACPI   working
Hotkeys   working with acerhk, see notes below

Hardware Details and Notes

Here is my complete linux kernel config file for kernel 2.4 and here for kernel 2.6.

ATM I am running 2.6.15-mm3 which includes cpufreq, laptop mode (see below), and the hostap drivers. The config file above compiles some drivers into the kernel, and some are left as modules for suspend support. Maybe it is not necessary since ATM suspend to disk works more or less without problems, and S2R also. See below. See the current (2.6) output of lsmod.

Previously I was running linux kernel 2.4, which I patched with cpufreq. Since 2.4.23-pre7 laptop mode is included. For completeness here the output of lsmod.


Sound

For kernel 2.6 I use alsa, with the options you find in the config file above (CONFIG_SND_*).

Alsa now supports also the modem, see below.

For kernel 2.4 use i810-audio.o (OSS), config option CONFIG_SOUND_ICH. Working perfectly.


USB

Working perfectly with the uhci host controler and the ehci for usb2.0. See the CONFIG_USB* in the config files for 2.4 and 2.6.

FireWire IEEE1394

Use ohci1394.o, config option CONFIG_IEEE1394_OHCI1394.

It works very nicely with my Maxtor OneTOuch II external hard disk, and udev/hotplug generates all the necessary /dev/sd* devices automatically.


AGPGART

Use agpgart with Intel support, config options CONFIG_AGP, CONFIG_AGP_INTEL. Working perfectly.

PCMCIA

Use yenta_socket.o, config options CONFIG_PCMCIA, CONFIG_CARDBUS, CONFIG_I82365. Working, not tested with any device.

TouchPad

The synaptics driver (homepage: http://w1.894.telia.com/~u89404340/touchpad/index.html) is in debian/sid, so it is enough to install xfree86-driver-synaptics. There is also qsynaptics and ksynaptics and tpconfig.

This driver supports multi finger taps, scrolling etc. See my xorg.conf for config options.


SD-Card Reader

This is an USB Device which can be used with usb-storage. Use config options CONFIG_USB_STORAGE. usb-storage is only the bridge to SCSI, so you have to have SCSI enable: CONFIG_SCSI, CONFIG_SCSI_SD. Then you should be able to find your sd card reader as /dev/sda1.

CD Writer

For kernel 2.6 I am now using NO scsi emulation and burn directly via /dev/hdc. Advantage, burning of audio cds also work in DMA modus (not true for ide-scsi).

For kernel 2.4 I am using ide-scsi emulation, config options CONFIG_BLK_DEV_IDESCSI. This model support burnfree, to get permanent activation put the following line into your /etc/default/cdrecord:

CDR_DEVICE=qsiata
qsi=		0,0,0	-1	-1	burnfree
qsiata=		/dev/hdc	-1	-1	burnfree

If you are using 2.4 set CDR_DEVICE to qsi in your shell, your /etc/profile, or in the above file, or for every job.


IRDA

Use the nsc-ircc module, config option CONFIG_NSC_FIR and the various CONFIG_IRDA_*. After this load the module with the following options by putting a this line into modules.conf (best via /etc/modutils/local and update-modules):

options nsc-ircc irq=3 io=0x02f8 dma=3 dongle_id=0x09

Additionally, you MUST disable the second serial port before loading the module. This can be done within debian by using /etc/serial.conf file, or calling
setserial /dev/ttyS1 uart none

Thanks to bernd at bernd-linz dot de, http://www.hawo.stw.uni-erlangen.de/%7Esibelinz/acerTM653LC.html

Syncing my palm works via /dev/ircomm0


Graphic, Radeon

With current Debian/sid you don't have to do anything. XOrg as shipped with Debian brings all the necessities.

You have to use the radeon drm modules, config options CONFIG_DRM, CONFIG_DRM_RADEON.

My complete xorg.conf config file is here. This includes options for the touchpad.

Woody and Radeon I got the following information from Marco Palestro (palestro () net4u dot it) concerning the installation of radeon modules on woody:

Radeon for woody, with linux-2.4.22

- put in kernel support for character devices / DRM
- didn't select the provided ATI Radeon module
- compiled and installed kernel (of course)
- downloaded radeon-config-20031011-linux.i386.tar.bz2 from ??
  and installed the kernel modules (using install.sh)
- added to /etc/apt/sources.list:
    deb http://people.debian.org/~daenzer/dri-trunk/ ./
- apt-get update; selected and installed packages:
    drm-trunk-module-src
    xlibmesa-dev-dri-trunk
    xlibmesa3-dri-trunk
    xserver-xfree86-dri-trunk
- in /etc/X11/XF86Config-4 configured the device to use module radeon.

- Be careful ! xserver-xfree86-dri-trunk uses an alternative directory for
  modules ! It's called "/usr/X11R6/lib/modules-dri-trunk"
  If you included in your XF86Config-4 lines with the directive ModulePath
  remember to modify them changing "modules" path with "modules-dri-trunk",
  or the xserver will try to load old xfree modules, crashing with segfault.
  Example:
    ModulePath    "/usr/X11R6/lib/modules-dri-trunk"
    ModulePath    "/usr/X11R6/lib/modules-dri-trunk/input"
(I guess the radeon-config-20031011-linux.i386.tar.bz2 above should be radeon-20031011-linux.i386.tar.bz2 (or later) from http://dri.sourceforge.net/snapshots/.)

Harddisk DMA

use config options CONFIG_BLK_DEV_PIIX, CONFIG_BLK_DEV_IDEDMA_PCI, CONFIG_IDEDMA_PCI_AUTO, CONFIG_BLK_DEV_IDEDMA, together with
hdparm -u1 -c1 -d1 /dev/hda

WLAN

I am using the hostap drivers at the moment in conjunction with wpa_supplicant. The hostap drivers are in the normal 2.6 kernel, and there is a debian package wpasupplicant.

For most uptodate information concerning WLAN on linux, please visit the most complete page on this: Wireless LAN resources for Linux by Jean Tourrilhes.


Modem

This is a Softmodem from SmartLink.

(3.3.05) No external kernel module needed. ALSA includes support for this modem, you only need the CONFIG_SND_INTEL8X0M and the sl-modem-daemon package (in debian/sid) and configure /etc/default/sl-modem-daemon for your country.


ACPI

Use current (>= 2.4.22 or 23-pre1) for ACPI support. Buttons work, battery charge state works.

ACPI DSDT table hacking

For a full explanation on how to do this please read all the documents on ACPI Web Site, and this extensive HOWTO on the Gentoo Discussion Forum.

The acpi implementation on this laptop does not deliver any ac_adapter events, which is a problem for using laptop_mode (see below). Thanks to various hints on the ACPI Web Site I fixed the dsdt table.

For this you need the dsdt-static-osl.diff patch for including a custom dsdt table into the kernel. Then you need a customized/fixed dsdt.hex table.

There are the following options:

  • Fix it yourself: YOu have to follow the above howto. I have applied three fixes to the dsdt: The first part fixes a missing return value:
    @@ -266,6 +266,7 @@
             }
     
             Store (0x00, \_SB.SLEE)
    +       Return(Package(0x02){0x00, 0x00})
         }
     
         Scope (_GPE)
    
    the second fixes the ac_adapter problem:
    @@ -3486,7 +3487,7 @@
     
                                     If (And (0x02, BATF))
                                     {
    -                                    Notify (\_SB.ACAD, 0x00)
    +                                    Notify (\_SB.ACAD, 0x80)
                                     }
     
                                     Notify (\_SB.BAT1, 0x80)
    
    the third fixes another missing return value problem:
    @@ -4762,6 +4763,10 @@
                                                 Return (0x0F)
                                             }
                                         }
    +                                    Else
    +                                    {
    +                                        Return (0x08)
    +                                    }
                                     }
                                     Else
                                     {
    
    This is all I had to do to fix my BIOS A37 dsdt table to compile again with iasl without any error.
  • Or you take my dsdt-fixed.hex (and/or the respective source file dsdt-fixed.dsl).

    You have to copy the dsdt-fixed.hex file into your kernel source linux-2.6.XXX/include/acpi/dsdt_table.h and recompile your kernel. Booting with the new kernel should give you something like this in the boot messages (dmesg):

        ACPI-0291: *** Info: Table [DSDT] replaced by host OS
    

    Then you can check wether unplugging/plugging the power gives ac_adapter events by making: cat /proc/acpi/events

    CPU power saving state hacking

    (3.3.05) I don't use this patch anymore, but I still have C2 working. I have no idea what did the change, but for now, forget everything what is written below (for current kernels the file processor.c does not even exists, it is processor_core.c).

    See below for interaction between laptop mode and acpi events.

    HACKING: DANGEROUS!!! The bios does disable the CPU power saving state C2 (and C3), which prevents the processor to enter this mode and conserve power. You can hack around this by using this patch, but I take no responsibility for a burned CPU and a ruined hardware. Good luck. I have this patch running since quiet some time without any problems and greatly decreased heat and increased battery life.

    Technical details: The bios programmers disabled C2 state by setting the latency limit to 101, which disables C2. With cpufreq and speedstep-ich C2 would save a lot of energy and battery life, the following patch skips the C2 latency test in drivers/acpi/processor.c. *This can damage your laptop* I have NO idea what are the consequences of this, but I have no problems with it (works with 2.6 and 2.4)

    I got this patch after a lengthy discussing with Dominik Brodowski who is responsible for the cpufreq drivers, too. His comments: (translated) The attached patch deletes the test wether the "latency" for C2 is larger than 100. Best would be to remount the file systems ro, then load processor.o module and check the stability before using it on a "live" system.

    I did this and till now I had now problems.


    CPU (freq scaling)

    Works nicely, cpufreq is included in 2.6 kernels, but you have to patch the 2.4 kernel. I cannot give a howto here, but use the speedstep driver. config options CONFIG_CPU_FREQ, CONFIG_CPU_FREQ_TABLE, CONFIG_CPU_FREQ_PROC_INTF, CONFIG_X86_SPEEDSTEP_ICH

    At the moment I am using cpufreqd for dynamically the speed of the processor together with this cpufreqd.conf config file. There are several other options (cpusyn, in kernel governors, ...).

    A thread on the cpufreq mailing list I started about which driver (clockmod vs. ich) and the differences, including heat/energy usage can be found here (unfortunately ATM only for list subscribers).


    Function Keys

    The Fn-Down and Fn-Up work, keycodes 174 and 176, resp. You can use hotkeys daemon or you windowmanager to let these keys do whatever you want.

    Using the latest version of the acerhk kernel driver (and a lot of help from Olaf Tauber, big thanks to him!) I got all keys to work. You have to load the module with modparam usedritek=1. Then the web and email buttons work, i.e. they send x keycodes!). TO get P1, P2, Help (Fn-F1) and Setup (Fn-F2) working, I had to set their kernel keycodes (as root) with setkeycode: My local init.d file calls the following commands:

    	setkeycodes e074 148
    	setkeycodes e073 149
    	setkeycodes e025 138
    	setkeycodes e026 141
    
    The complete table I collected (which is a bit different compared to the doc/keycodes infos from the acerhk distribution) looks like this:
    Key		scancode	kernel-keycode	X-keycode
    P1		e074		148 (KEY_PROG1)		159
    P2		e073		149 (KEY_PROG2)		151
    Help(FN-F1)	e025		138 (KEY_HELP)		245
    Setup(Fn-F2)	e026		141 (KEY_SETUP)		193
    
    WLAN on		e055
    WLAN off	e056
    
    BlueTooth on	e057
    BlueTooth off	e058
    
    Working without setkeycodes intervention
    Email				155 (KEY_MAIL)		236
    Net				150 (KEY_WWW)		178
    VolUp				115 (KEY_VOLUMNEUP)	176
    VolDown				114 (KEY_VOLUMEDOWN)	174
    Mute(Fn-F8)			113 (KEY_MUTE)		160
    
    I am using this keyboard definition file with the hotkeys daemon to get access to all function keys.

    Laptop Mode

    laptop-mode is in the kernel and the scripts are in debian sid, package laptop-mode-tools.

    Suspend to disk and RAM

    Suspend to disk

    S2D seems to work for me pretty well. Even from a running X. I only have to stop the mysql server. Here is my acpi suspendtodisk.sh script.

    I have to remove the network module b44 because it crashed several times when resuming. I am investigating this, maybe I can get rid of the unloading/loading.

    Suspend to RAM

    Currently I can suspend to RAM and disk without any features and tricks, no external programs are necessary.

    Here is my current ACPI suspendtoram.sh script which you have to put (like the suspendtodisk.sh) into /etc/acpi/actions and configure events in /etc/acpi/events.

    Not working or not tried stuff

    SmartCard reader

    (C) 2003-2006, Norbert Preining, preining at logic dot at