XO-1.5 A1 HDA issues

Daniel Drake dsd at laptop.org
Mon Jun 29 08:17:35 EDT 2009


Hi,

I've been looking into the sound issue where we could not record any
audio from Linux on the XO-1.5 A1.

I now have it working. I have observed a few low-level sound issues
though. Many thanks to Tony Vroon for some helpful input here.

Firstly, the issue was that there are 3 microphone mixers available at
the software level and the default one ("Mic") doesn't seem to record
anything from either the internal microphone or a microphone plugged
into the jack.

The other 2 ("Mic 1" and "Mic 2") both record simultaneously from both
the external and internal microphones. Setting the capture device to Mic
1 and setting an appropriate capture level "solves" our sound recording
issues.

http://dev.laptop.org/ticket/9388 internal mic should be automuted
http://dev.laptop.org/ticket/9389 strange mixer arrangement

While experimenting, I noticed that the internal speakers are not muted
when headphones are plugged in. http://dev.laptop.org/ticket/9386

I also noticed that the Master volume control has a ridiculously huge
range in that it lets you turn down the volume *really* low.
http://dev.laptop.org/ticket/9387

So, while we aren't in too bad shape, we should improve on a few things.
Internal speaker automute would be a good starting point so I started to
investigate...

These kinds of problems are common in the HDA world, and the usual
process is to use the PCI subsystem vendor and product IDs to identify
the exact model of laptop being used (this is usually customised by the
laptop vendor e.g. the Intel HDA chip in my main laptop has a Dell
subvendor ID and a Dell-assigned subproduct ID) and apply some
workarounds. Of course, all users of this chip would want internal
speaker automute when headphones are present, but the wiring will vary
so much from laptop to laptop that such code would almost certainly need
to be XO-specific as it is for all the other laptops in the world.
At the moment we do not appear to have customised the PCI
subvendor/subproduct IDs in any way. http://dev.laptop.org/ticket/9390

Now onto attacking the actual issue... The Conexant codec support in the
kernel does not support our chip, which is the CX20582. As a result, we
can't just trivially add OLPC laptop quirks to the CX20582 code because
there is none. The generic HDA parser is being used instead.

Can we get the CX20582 technical docs?

I sent an email to the alsa developers list just in case someone could
write such code without the documentation, but this seems unlikely.
http://mailman.alsa-project.org/pipermail/alsa-devel/2009-June/018978.html

Also, is there scope to improve the default pin settings in the hardware
so that we don't have to quirk anything? Right now they seem to offer
all kinds of irrelevant pin settings including 4 microphone ports and
support for a docking station.

While we're on the topic, we also have some sound playback issues.
http://dev.laptop.org/ticket/9373 tamtam sound is crackly
http://dev.laptop.org/ticket/9375 scratch sounds are jumpy
Possibly related, I recall seeing some warning messages in dmesg a few
times, something about the HDA driver having to apply some kind of IRQ
workaround. I'll file a bug next time I see it.

Here is some more information.
codec dump
http://dev.laptop.org/~dsd/20090629/codec0.txt

codec graph
http://dev.laptop.org/~dsd/20090629/codecgraph.svg

lspci entry
http://dev.laptop.org/~dsd/20090629/lspci-entry.txt

verbose dmesg from probing
http://dev.laptop.org/~dsd/20090629/dmesg-probe.txt


Daniel





More information about the Devel mailing list