On Sun, Apr 26, 2009 at 12:43 PM, Jaroslav Kysela <perex@xxxxxxxx> wrote: > On Sun, 26 Apr 2009, Jon Smirl wrote: > >> Here's the code computing the mpc5200 dma pointer. Could you please >> take a look at it and let me know what it is doing wrong. > > I think that the culprit of your problems is that your code expects that > buffer_size / period_size is an integer value (whole period is placed inside > ring buffer). But if you do not instruct the high level code of ALSA in > open() callback by calling snd_pcm_hw_constraint_integer(runtime, > SNDRV_PCM_HW_PARAM_PERIODS) to do so - see other drivers - then period might > be also placed across the buffer_size boundary - which appearently makes > your current problems. > > I think that bcom_submit_next_buffer() expects continuous memory (thus whole > period), right? Yes, it wants continuous memory. I added SNDRV_PCM_HW_PARAM_PERIODS and things are working better. That was a better solution than breaking up operations into multiple DMA requests. > > Jaroslav > > ----- > Jaroslav Kysela <perex@xxxxxxxx> > Linux Kernel Sound Maintainer > ALSA Project, Red Hat, Inc. > > -- Jon Smirl jonsmirl@xxxxxxxxx _______________________________________________ Alsa-devel mailing list Alsa-devel@xxxxxxxxxxxxxxxx http://mailman.alsa-project.org/mailman/listinfo/alsa-devel