Lines Matching defs:runtime

93 	struct snd_pcm_runtime *runtime = substream->runtime;
96 unsigned char stereo = runtime->channels > 1;
99 rate = runtime->rate;
102 if (runtime->format == SNDRV_PCM_FORMAT_S16_LE) {
111 if (runtime->channels > 1) {
157 runtime->dma_area[0] = 0x80;
158 snd_dma_program(dma, runtime->dma_addr, 1, DMA_MODE_WRITE);
166 snd_sbdsp_command(chip, 256 - runtime->rate_den / 2);
175 snd_sbdsp_command(chip, 256 - runtime->rate_den);
186 snd_dma_program(dma, runtime->dma_addr,
209 struct snd_pcm_runtime *runtime = substream->runtime;
211 if (runtime->channels > 1) {
227 struct snd_pcm_runtime *runtime = substream->runtime;
230 unsigned char stereo = runtime->channels > 1;
233 rate = runtime->rate;
236 if (runtime->format == SNDRV_PCM_FORMAT_S16_LE) {
245 if (runtime->channels > 1) {
287 snd_sbdsp_command(chip, 256 - runtime->rate_den / 2);
296 snd_sbdsp_command(chip, 256 - runtime->rate_den);
307 snd_dma_program(dma, runtime->dma_addr,
330 struct snd_pcm_runtime *runtime = substream->runtime;
332 if (runtime->channels > 1) {
391 return bytes_to_frames(substream->runtime, ptr);
407 return bytes_to_frames(substream->runtime, ptr);
459 struct snd_pcm_runtime *runtime = substream->runtime;
468 runtime->hw = snd_sb8_playback;
471 runtime->hw = snd_sb8_capture;
476 runtime->hw.formats |= SNDRV_PCM_FMTBIT_S16_LE;
477 runtime->hw.rates |= SNDRV_PCM_RATE_8000_48000;
478 runtime->hw.rate_min = 4000;
479 runtime->hw.rate_max = 50000;
480 runtime->hw.channels_max = 2;
483 runtime->hw.rate_max = 44100;
484 runtime->hw.channels_max = 2;
485 snd_pcm_hw_rule_add(runtime, 0, SNDRV_PCM_HW_PARAM_RATE,
489 snd_pcm_hw_rule_add(runtime, 0, SNDRV_PCM_HW_PARAM_CHANNELS,
495 runtime->hw.rate_max = 44100;
497 runtime->hw.rate_max = 15000;
503 snd_pcm_hw_constraint_ratnums(runtime, 0, SNDRV_PCM_HW_PARAM_RATE,
506 snd_pcm_hw_constraint_step(runtime, 0,
508 snd_pcm_hw_constraint_step(runtime, 0,
510 runtime->hw.buffer_bytes_max = 128 * 1024 * 1024;
511 runtime->hw.period_bytes_max = 128 * 1024 * 1024;