diff options
author | Takashi Iwai <tiwai@suse.de> | 2009-06-02 09:26:19 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2009-06-02 09:54:47 -0400 |
commit | c76157d9286ed598c241c212aa5a3c6e5107bd82 (patch) | |
tree | a08d4b06184bf37ee55a20e30f9c66a43cee37c2 /sound/pci/ctxfi/ctpcm.c | |
parent | cd391e206f486955e216a61bd9ebcb0e142122e9 (diff) |
ALSA: ctxfi - Support SG-buffers
Use SG-buffers instead of contiguous pages.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/ctxfi/ctpcm.c')
-rw-r--r-- | sound/pci/ctxfi/ctpcm.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sound/pci/ctxfi/ctpcm.c b/sound/pci/ctxfi/ctpcm.c index 26d86dc35e52..52ddf19d83bb 100644 --- a/sound/pci/ctxfi/ctpcm.c +++ b/sound/pci/ctxfi/ctpcm.c | |||
@@ -442,6 +442,7 @@ static struct snd_pcm_ops ct_pcm_playback_ops = { | |||
442 | .prepare = ct_pcm_playback_prepare, | 442 | .prepare = ct_pcm_playback_prepare, |
443 | .trigger = ct_pcm_playback_trigger, | 443 | .trigger = ct_pcm_playback_trigger, |
444 | .pointer = ct_pcm_playback_pointer, | 444 | .pointer = ct_pcm_playback_pointer, |
445 | .page = snd_pcm_sgbuf_ops_page, | ||
445 | }; | 446 | }; |
446 | 447 | ||
447 | /* PCM operators for capture */ | 448 | /* PCM operators for capture */ |
@@ -454,6 +455,7 @@ static struct snd_pcm_ops ct_pcm_capture_ops = { | |||
454 | .prepare = ct_pcm_capture_prepare, | 455 | .prepare = ct_pcm_capture_prepare, |
455 | .trigger = ct_pcm_capture_trigger, | 456 | .trigger = ct_pcm_capture_trigger, |
456 | .pointer = ct_pcm_capture_pointer, | 457 | .pointer = ct_pcm_capture_pointer, |
458 | .page = snd_pcm_sgbuf_ops_page, | ||
457 | }; | 459 | }; |
458 | 460 | ||
459 | /* Create ALSA pcm device */ | 461 | /* Create ALSA pcm device */ |
@@ -485,7 +487,7 @@ int ct_alsa_pcm_create(struct ct_atc *atc, | |||
485 | snd_pcm_set_ops(pcm, | 487 | snd_pcm_set_ops(pcm, |
486 | SNDRV_PCM_STREAM_CAPTURE, &ct_pcm_capture_ops); | 488 | SNDRV_PCM_STREAM_CAPTURE, &ct_pcm_capture_ops); |
487 | 489 | ||
488 | snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_DEV, | 490 | snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_DEV_SG, |
489 | snd_dma_pci_data(atc->pci), 128*1024, 128*1024); | 491 | snd_dma_pci_data(atc->pci), 128*1024, 128*1024); |
490 | 492 | ||
491 | return 0; | 493 | return 0; |