[alsa-devel] [PATCH] pcm: softvol: add support for S24_LE

Jörg Krause joerg.krause at embedded.rocks
Tue Sep 12 08:13:37 CEST 2017


On Fri, 2017-09-08 at 12:52 +0200, Clemens Ladisch wrote:
> Jörg Krause wrote:
> > Tested with a Wolfson WM8524 DAC on a i.MX6UL board running Linux version
> > 4.13.0-next-20170907.
> > +	case SND_PCM_FORMAT_S24_LE:
> > +		/* 24bit samples, fallthrough */
> >  	case SND_PCM_FORMAT_S32_LE:
> 
> S24_LE cannot be handled with the same algorithm as S32_LE.

That would have been too easy.

> I suspect that the hardware does not actually use S24_LE, and
> that the driver uses the wrong label for this format.

Maybe you are right about that. I will have a look.

> Please describe exactly how the 24-bit sample is aligned into
> the 32-bit memory cell.

According to this old post [1] it is aligned as followed:

00ffff3f 00ffff3f 00ebd96e 00ebd96e 00ffff7f 00ffff7f
Meaning the left-most byte is zeroed, right?

[1] http://mailman.alsa-project.org/pipermail/alsa-devel/2008-July/0090
99.html

Best regards,
Jörg Krause


More information about the Alsa-devel mailing list