Please support EEEPC 901 Variant of the ALC269 snd_hda_intel

Bug #259878 reported by Daniel Miles on 2008-08-20
34
This bug affects 2 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Wishlist
Unassigned

Bug Description

Binary package hint: linux-image

When installing on an eeepc 901, the internal microphone does not work. This is a different bug to the other models of eee.

This is fixed by properly supporting the ALC269 Intel High Definition Audio chip. This can be done by updating alsa to 1.0.18rc1, or by patching the snd_hda_intel driver to include this functionality.

A patch written by Adamm from the eeeusers forum is attached - all work done on this is his. It is suitable for version 1.0.16 of alsa, which, according to my apt, we still use in Intrepid rather than 1.0.17?

This is on Kubuntu intrepid, all updates current.

Daniel Miles (themono) wrote :
Kenneth Bingham (qrkourier) wrote :

I am trying to apply the patch on a eeepc1000, and am not yet certain how to proceed based on the error ouput below. Do I have the wrong idea completely?

$ cd /usr/local/src/
$ sudo apt-get source alsa-modules-2.6.24-21-eeepc
$ sudo wget http://launchpadlibrarian.net/16966650/ubuntu-hardy-lum%2Balsa_eeepc901_fix.diff
$ sudo patch /usr/local/src/alsa-driver-1.0.16/pci/hda/patch_realtek.c ./ubuntu-hardy-lum+alsa_eeepc901_fix.diff
Hunk #1 FAILED at 30.
Hunk #2 FAILED at 119.
Hunk #3 FAILED at 10305.
Hunk #4 FAILED at 10343.
Hunk #5 FAILED at 10399.
Hunk #6 FAILED at 10413.
Hunk #7 FAILED at 10476.
Hunk #8 FAILED at 10699.
Hunk #9 FAILED at 10726.
Hunk #10 FAILED at 10744.
patch unexpectedly ends in middle of line
Hunk #11 FAILED at 10821.
11 out of 11 hunks FAILED -- saving rejects to file /usr/local/src/alsa-driver-1.0.16/pci/hda/patch_realtek.c.rej

Kenneth Bingham (qrkourier) wrote :

This seems to have worked, now to figure out how to replace the currently installed module with a newly compiled one...

$ mv ./ubuntu-hardy-lum+alsa_eeepc901_fix.diff ./alsa-driver-1.0.16/
$ sudo patch -p3 < ./ubuntu-hardy-lum+alsa_eeepc901_fix.diff
patching file alsa-kernel/pci/hda/patch_realtek.c
Hunk #3 succeeded at 10303 (offset -2 lines).
Hunk #4 succeeded at 10341 (offset -2 lines).
Hunk #5 succeeded at 10397 (offset -2 lines).
Hunk #6 succeeded at 10411 (offset -2 lines).
Hunk #7 succeeded at 10474 (offset -2 lines).
Hunk #8 succeeded at 10697 (offset -2 lines).
Hunk #9 succeeded at 10724 (offset -2 lines).
Hunk #10 succeeded at 10742 (offset -2 lines).
patch unexpectedly ends in middle of line
Hunk #11 succeeded at 10819 with fuzz 1 (offset -2 lines).

Adam McDaniel (adamrmcd) wrote :

Once you've compiled your patched alsa modules, you only need to replace snd_hda_intel.ko
You can probably get away with replacing the version under /lib/modules/$(uname -r)/ubuntu/sound/alsa-driver/pci/hda/snd_hda_intel.ko with the new version.

Once applied, you can probably get away with 'sudo alsa force-reload', however I found rebooting was safer.

You'll know that it worked if you now see a 'Front Mic' and 'Front Mic Boost' as available mixer channels.
Also, you should also see 'Headphone' as a variable output channel.

Kenneth Bingham (qrkourier) wrote :

After these steps I do have a "Front Mic" and "Front Mic Boost" on tab "Playback", and a toggle "Headphone" on tab "Switches". I still have nothing but static from the capture channel "Front Mic".

After I patched the source I ran:
$ sudo ./configure && make && make install
$ sudo cp /usr/local/src/alsa-driver-1.0.16/modules/snd-hda-intel.ko /lib/modules/2.6.24-21-eeepc/ubuntu/sound/alsa-driver/pci/hda/snd-hda-intel.ko
...then rebooted

Sound works from all sources except capture, as before.

$ uname -r
2.6.24-21-eeepc
$ lspci
00:1b.0 Audio device: Intel Corporation 82801G (ICH7 Family) High Definition Audio Controller (rev 02)
$ cat /proc/asound/*
cat: /proc/asound/card0: Is a directory
 0 [Intel ]: HDA-Intel - HDA Intel
                      HDA Intel at 0xf7db8000 irq 16
  0: [ 0] : control
  1: : sequencer
  4: [ 0- 0]: hardware dependent
 16: [ 0- 0]: digital audio playback
 24: [ 0- 0]: digital audio capture
 33: : timer
00-00: HDA Codec 0
cat: /proc/asound/Intel: Is a directory
 0 snd_hda_intel
cat: /proc/asound/oss: Is a directory
00-00: ALC269 Analog : ALC269 Analog : playback 1 : capture 1
cat: /proc/asound/seq: Is a directory
G0: system timer : 4000.000us (10000000 ticks)
P0-0-0: PCM playback 0-0-0 : SLAVE
P0-0-1: PCM capture 0-0-1 : SLAVE
Advanced Linux Sound Architecture Driver Version 1.0.16.
Compiled on Aug 12 2008 for kernel 2.6.24-21-eeepc (SMP).

Adam McDaniel (adamrmcd) wrote :

The "Capture" channel may not be properly set.

Have a look at this post: http://forum.eeeuser.com/viewtopic.php?pid=347484#p347484

(BTW, since you're running 2.6.24-21-eeepc, check which version of linux-ubuntu-modules-2.6.24-21-eeepc is installed. The latest is 2.6.24-21.30eeepc3, and its snd_hda_intel.ko module already has this patch. Likely, the capture mixer setting was the only thing that needed to be set:)

Kenneth Bingham (qrkourier) wrote :

The mic icon titled "Toggle audio recording from this channel" on channel "Capture" on tab "Recording" in gnome volume control appears to correspond to the "CAPTUR" toggle in alsamixer. It was already enabled.

I performed the steps below which presumably replaced the patched version I compiled from source, rebooted, and found no change in the result.

$ sudo aptitude show linux-ubuntu-modules-2.6.24-21-eeepc
Package: linux-ubuntu-modules-2.6.24-21-eeepc
New: yes
State: installed
Automatically installed: yes
Version: 2.6.24-21.30eeepc3
Priority: optional
Section: universe/base
Maintainer: Ubuntu Kernel Team <email address hidden>
Uncompressed Size: 16.4M
Depends: linux-image-2.6.24-21-eeepc
PreDepends: dpkg (>= 1.10.24)
Provides: ndiswrapper-modules-1.9
Description: Ubuntu supplied Linux modules for version 2.6.24 on x86/x86_64
 This package contains modules supplied by Ubuntu for Linux kernel 2.6.24 on
 x86/x86_64.

 You likely do not want to install this package directly. Instead, install the
 linux-eeepc meta-package, which will ensure that upgrades work correctly, and
 that supporting packages are also installed.

$ sudo aptitude reinstall linux-eeepc

Adam McDaniel (adamrmcd) wrote :

This entire ticket might no longer be necessary.

According to the alsa-kmirror git repository, The release tagged "v1.0.18rc3" contains the fix for the 901 and 1000

Daniel T Chen (crimsun) wrote :

Already fixed upstream. Perhaps mergeable for 8.10, which uses 1.0.17 (not 1.0.16 as mistakenly referred to in a comment above).

Changed in alsa-driver:
importance: Undecided → Wishlist
status: New → Confirmed
Daniel Miles (themono) wrote :

It was correct at the time of writing - we moved to .17 with kernel .27

Adam McDaniel (adamrmcd) wrote :

Earlier, Intrepid used Alsa v1.0.16. Now, Intrepid uses Alsa v1.0.17.
Intrepid's alsa-kernel code does have support for the EeePC 901, However support for the 1000 is not yet included.

According to git://git.alsa-project.org/alsa-kmirror.git this is provided by commit:
231d8534cf252135646b47e45e2149285b3df0ea : ALSA: hda - Add support of Quanta FL1

n.b.: commit 231d853 provided support for the Quanta FL1, however the author bundled the EeePC 1000 device/vendor id check in there too, subsequently treating it like a 901... Technically, only two lines of this commit need to be patched.

So, If someone wanted to support the 1000 on v1.0.17, then they'd need to import commit 231d853, *OR* just this chunk (see attached).

If Alsa v1.0.18 (or this patch) does not make it into Intrepid, then at worst the 1000 will not have Internal Microphone support, nor will the speakers/headphones mute/unmute properly. Everything else on the 1000 should work with v1.0.17.

Sitsofe Wheeler (sitsofe) wrote :

This looks related to Bug #232173 (although sadly that bug is less specific that this one). How did Intrepid miss support for the 901? Didn't support go into the upstream 2.6.27 kernel? - http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=f53281e62a41ac176f050307c0d746a1183a68e8 .

Pontus Freyhult (pontusf) wrote :

I'm somewhat confused. With an up to date intrepid (2.6.27-4-generic), sound works except for the built-in microphone.

If I get alsa-source, patch with <http://launchpadlibrarian.net/16966650/ubuntu-hardy-lum%2Balsa_eeepc901_fix.diff> and use that, I get the extra mixer channels, but I still only manage to get static, just like <https://bugs.launchpad.net/ubuntu/+source/alsa-driver/+bug/259878/comments/5>.

Interesting enough, if I get 1.0.18rc3 from alsa-project.org (<ftp://ftp.alsa-project.org/pub/driver/alsa-driver-1.0.18rc3.tar.bz2>) and use that, I don't get those extra mixer channels - and the mic still doesn't work.

Pontus Freyhult (pontusf) wrote :

Seems to have been a problem between keyboard and chair - upon reverting to the very same patched 1.0.17 that I previously tried, doing (as far as I know) the same thing as earlier, I can now record from the mic without problems.

Adam McDaniel (adamrmcd) wrote :

After applying the alsa_eeepc901_fix.diff patch, there are some specific alsamixer settings that need to be set on those new channels, otherwise the new channels wont actually record. (Note, most users cite Skype as their software use-case, Skype just seems to do the "right thing" when presented with these additional channels, hence the lack of earlier instructions:) ... Here's what I use to set the alsa channels on the command-line (the same can be performed with gnome-volume-control and alsamixer, but I find using this 'amixer' example as easier to get the point across):

  amixer sset "Input Source" "Front Mic"
  amixer sset "Capture" "80%" "cap" "unmute"
  amixer sset "Front Mic Boost" "30%" "unmute"
  amixer sset "Front Mic" "100%" "mute"

Note1: That muted "Front Mic" refers to the output channel. Unmuting this will result in some nasty feedback between the internal mic and speakers.

Note2: Running this command on Intrepid may also require "-c 0" before sset. It might have been my own wonky alpha5 install settings, but for some reason PulseAudio was the default card <shrug>

Note3: I *believe* these four channels are available on ANY eeepc (700-1000h) with the appropriate patch installed, however I only actually own a 900. If one of these commands fail, run "amixer" and study the output before giving up.

Can anyone confirm this is now resolved with the latest Jaunty release - http://www.ubuntu.com/getubuntu/download . Thanks.

Changed in linux (Ubuntu):
status: Confirmed → Incomplete
Pontus Freyhult (pontusf) wrote :

I've now tested with ALSA from linux-image-2.6.28-13-generic and recording with the built in microphone works.

Changed in linux (Ubuntu):
status: Incomplete → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers