[Arm-netbook] ALSA info - trying to get sound working
Luke Kenneth Casson Leighton
luke.leighton at googlemail.com
Thu Mar 25 21:46:34 GMT 2010
On Thu, Mar 25, 2010 at 9:11 PM, Frans Pop <elendil at planet.nl> wrote:
> The ALSA controls are completely weird,
welcome to embedded arm kernel development. it is _complete_ chaos.
the pxa25x and 27x devices, we had so many HTC phones being
reverse-engineered... russell set an arbitrary rule: "only 3
subdirectories deep". we had a bit of a laugh about that one, because
we had ONE HUNDRED AND FORTY files in 4-level subdirectories, 15 to 20
or so in each, because of the sheer number of pxa2xx-based htc ipaq
and smartphone platforms that people were reverse-engineering. we
didn't hear back about that one.
> I'm not sure that s3c24xx_pcm_open is exactly the correct place.
> Reason is that when I add it there the volume is reset (to very loud) each
> time I run ogg123. This seems to indicate that now the hardware is getting
> reset each time a song is played, which seems incorrect.
also - this could be related - there is s3c6400_ac97_read being
called twice and s3c6400_ac97_write being called twice - in both open
and close. these are _supposed_ to be static functions: looks like
they got modified to be public *sigh*.... but it couuuld be that it's
because soc_ac97_ops->read / write are being accessed, and this is
just compiler optimisation anyway *shrugs* -
code goes something like this:
R4 = s3c6410_ac97_read(NULL, 4);
R5 = s3c6410_ac97_read(NULL, 0x18);
R2 = R4 << 17;
R2 >>= 17;
s3c6410_ac97_write(NULL, 4, R2);
R2 = R5 << 17;
R2 >>= 17;
s3c6410_ac97_write(NULL, 0x18, R2);
it looks like the same in s3c24xx_pcm_close, except that it's <<19
and >>= 19 for the 2nd one, hard to tell with the assembler being 0x75
0x20 0xff 0xe6 not properly disassembled.
in open, those two bug-ugly calls are made _after_ the
snd_soc_set_runtime_hwparams.
l.
More information about the Arm-netbook
mailing list