[alsa-devel] [PATCH] [ALSA] mpc8610: Add mmap support

Trent Piepho xyzzy at speakeasy.org
Thu Jan 17 22:40:23 CET 2008


On Thu, 17 Jan 2008, Timur Tabi wrote:
> Alexander E. Patrakov wrote:
> > Timur Tabi wrote:
> >> Enable mmap support in the MPC8610 ASoC driver.  The driver can use
> >> ALSA's
> >> default mmap functionality, it was just not enabled previously.
> >>
> >> Signed-off-by: Timur Tabi <timur at freescale.com>
> >
> > [sorry, I may be completely wrong below about the .page callback purpose
> > - in this case, just confirm that the testcase works]
> >
> > Hm, the "struct snd_pcm_ops fsl_dma_ops" doesn't contain the .page
> > callback. With saa7134-alsa, this led to the "device claims to support
> > mmap but actually doesn't work" bug, see the following subthread:
>
> Isn't that an ARM chip?  The default MMAP handler in ALSA doesn't support ARM,
> but it works for PowerPC.

Alexander is talking about the same thing I was in my previous message to
you.  saa7134, like cx88-alsa, uses vmalloc instead of ALSA to allocate the
DMA buffer, and so a special page callback is needed.

> I haven't tried record, but I did try playback, and it worked.  Without this
> patch, adding -M gives me this error:
>
> aplay: set_params:852: Access type not available
>
> After applying this patch, playback works fine.

The key thing to know is that you will not get an error message if your
page callback is wrong!  Everything will appear to work.  You just won't
hear any sound.


More information about the Alsa-devel mailing list