Archive for the ‘Intel’ Category

Weird Intel-HDA!

Posted: January 29, 2008 in Intel, Linux

I am the kind of Linux user would try out the latest Linux kernel whenever there is a new release. So, with the new release of kernel 2.6.24, I download it and install into my laptop.

Everything seems to be working fine. Unfortunately, the onboard sound card went silence after the update.

Some background information before I continue:

  • Laptop: Dell Vostro 1400
  • Card: HDA Intel
  • Chip: SigmaTel STAC9228

In order to get it working, I need to install ALSA version 1.0.15 and add “model=5stack” into the sound card module options. This was done with considerablely many trial-and-error attempts in order to figure out the proper option for my box. This setup been working since kernel 2.6.21.x to 2.6.23.x, until now…

Below is a summary of what had happened:

  • First I try the driver comes with kernel 2.6.24 – This does not work.
  • I tried alsa-1.0.15, but it can’t be built – This does not work.
  • I must download the latest RC in order to get it build and installed into my system. But, still no sound. – This does not work either.
  • I remove the “model=5stack” option and run alsaconf to redetect my sound card again. This work! Finally!
  • But, the “Front” and “Surround” got swapped! I have to goto GNOME sound preference to change the default Mixer – to get sound buttons working again for my laptop.

Searching HDA Intel or Intel-HDA at Google, I notice many users also complaining about this card (for various other problem). I must say, of all my years of playing with Linux, I never had this kind of weird problem for a sound card.


Recently, I got myself a Dell Inspiron 640m laptop. Looking at its spec: Core 2 T5300, 2GB RAM and Intel 945GM Express Integrated Graphics Controller, I realised, it is ideal to try out Compiz + AIGLX.

As I had done some reading over the net and knowing this time round, it seems this card should be quite simple to configured for Compiz + AIGLX. To my surprise, is not as simple as I had initially thought.

Today this article is about my attempt to get Compiz + AIGLX works with this system.

Let’s start by giving out some information of the system:

# lspci
00:00.0 Host bridge: Intel Corporation Mobile 945GM/PM/GMS, 943/940GML and 945GT Express Memory Controller Hub (rev 03)
00:02.0 VGA compatible controller: Intel Corporation Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller (rev 03)
00:02.1 Display controller: Intel Corporation Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller (rev 03)

00:1b.0 Audio device: Intel Corporation 82801G (ICH7 Family) High Definition Audio Controller (rev 01)
00:1c.0 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 1 (rev 01)
00:1c.1 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 2 (rev 01)
00:1c.3 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 4 (rev 01)
00:1d.0 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #1 (rev 01)
00:1d.1 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #2 (rev 01)
00:1d.2 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #3 (rev 01)
00:1d.3 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #4 (rev 01)
00:1d.7 USB Controller: Intel Corporation 82801G (ICH7 Family) USB2 EHCI Controller (rev 01)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev e1)
00:1f.0 ISA bridge: Intel Corporation 82801GBM (ICH7-M) LPC Interface Bridge (rev 01)
00:1f.2 IDE interface: Intel Corporation 82801GBM/GHM (ICH7 Family) SATA IDE Controller (rev 01)
00:1f.3 SMBus: Intel Corporation 82801G (ICH7 Family) SMBus Controller (rev 01)
02:00.0 Ethernet controller: Broadcom Corporation BCM4401-B0 100Base-TX (rev 02)
02:01.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller
02:01.1 Generic system peripheral [0805]: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 19)
02:01.2 System peripheral: Ricoh Co Ltd Unknown device 0843 (rev 01)
02:01.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 0a)
02:01.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 05)
0c:00.0 Network controller: Intel Corporation PRO/Wireless 3945ABG Network Connection (rev 02)

Note the text in bold, there seems to be two display controllers in the system. Perhaps one is meant for external monitor, but in this little exercise, I only configure 00:02.0 not 00:02.1.

  • Setup X

The base system that I will be using is Slackware 12 rc1. Following the instructions from Intel I manage to build the kernel modules and activate it. As of now, it seems kernel DRI for intel is older version than the link given by Intel.After that, run xorgcfg to create an initial xorg.conf at /etc/X11. From here, manually edit the generated xorg.conf:

Section “Module”
Load “dri”
Load “dbe”
Load “extmod”
Load “glx”
Load “xtrap”
Load “freetype”
Load “type1”
Load “record”


Section “Device”
Identifier “Card0”
Driver “intel”
VendorName “Intel Corporation”
BoardName “Mobile 945GM/GMS/940GML Express Integrated Graphics Controller”
BusID “PCI:0:2:0”
Option “CacheLines” “32768”
Option “DRI” “true”
Option “AccelMethod” “EXA”
Option “PageFlip” “true”
Option “TripleBuffer” “true”

I discover if I use the default X acceleration method of XAA, I can’t play any movies in XV. It keep giving error of lack of resources. Switching it to EXA solve the problem.

(update) Added Option for “PageFlip” and “TripleBuffer” – This should improve 3D performance (since I am using Compiz with all the visual stuff, I think this should be enabled).

Finally, make sure the following sections are added:

Section “DRI”
Mode 0666

Section “Extensions”
Option “Composite” “Enable”

Once we reached here, X should be configured with DRI+AIGLX+Composite. Next we need to setup compiz.

  • Setup Compiz

From here, install Compiz and gnome-compiz-manager. I am using DLG, so the following steps are more related with Gnome than KDE.

1st – Create shell script for starting compiz:


LIBGL_ALWAYS_INDIRECT=1 compiz –replace –sm-disable gconf &
gtk-window-decorator –replace &

I name this file as compiz-start and save it in /usr/bin directory. LIBGL_ALWAYS_INDIRECT is needed here. If this is not set, compiz won’t start.

(update) add –sm-disable option fix the session problem.

2nd – Add compiz-start into the session.


Once this is done, exit and login again, compiz should be running now.

3rd – The next step will be configuring the plugins. Launch gconf-editor, edit /app/compiz/general/allscreens/options, make sure active_plugins is the following order:

gconf, dbus, svg, png, decoration, minimize, wobbly, fade, cube, rotate, switcher, move, resize, place, zoom, scale, annotate

4th – Fix the workspace switch problem by referring to this link: Workspace Switcher Fix

Once we reached here, compiz should be working with all the nice effect. Enjoy!

  • Issues:
  • Even though full acceleration is working, it is unable to run glxgear (a 3D application) properly. This will imply 3D application will encounter problem when execute. It is being reported as a known bug. Below is the link for the bug report:
    Since it is still a know bug, and resolution has not been work out, there is no suggestion to resolve this problem.
  • Movie playback is working. However, if GL is enable, playing movie in full screen will be jerky.