Lines Matching refs:bpos
53 unsigned int bpos;
138 curr = begin + (pcmp->bpos * pcmp->block_size) / runtime->channels;
213 pcmp->bpos++;
214 pcmp->bpos %= pcmp->blocks;
215 if (pcmp->bpos + 1 >= pcmp->blocks) { /* last block? */
220 end = pcmp->memory + (((pcmp->bpos + 1) * pcmp->block_size) / runtime->channels);
343 unsigned int bpos, len;
345 bpos = samples_to_bytes(runtime, pos) + (voice * (pcmp->dma_size / 2));
347 if (snd_BUG_ON(bpos > pcmp->dma_size))
349 if (snd_BUG_ON(bpos + len > pcmp->dma_size))
351 if (copy_from_user(runtime->dma_area + bpos, src, len))
354 return snd_gf1_pcm_block_change(substream, bpos, pcmp->memory + bpos, len);
361 if ((err = snd_gf1_pcm_poke_block(gus, runtime->dma_area + bpos, pcmp->memory + bpos, len, w16, invert)) < 0)
374 unsigned int bpos, len;
376 bpos = samples_to_bytes(runtime, pos) + (voice * (pcmp->dma_size / 2));
378 if (snd_BUG_ON(bpos > pcmp->dma_size))
380 if (snd_BUG_ON(bpos + len > pcmp->dma_size))
382 snd_pcm_format_set_silence(runtime->format, runtime->dma_area + bpos, count);
384 return snd_gf1_pcm_block_change(substream, bpos, pcmp->memory + bpos, len);
391 if ((err = snd_gf1_pcm_poke_block(gus, runtime->dma_area + bpos, pcmp->memory + bpos, len, w16, invert)) < 0)
472 pcmp->bpos = 0;