diff options
Diffstat (limited to 'sound/mips')
-rw-r--r-- | sound/mips/Kconfig | 12 | ||||
-rw-r--r-- | sound/mips/hal2.c | 3 | ||||
-rw-r--r-- | sound/mips/sgio2audio.c | 12 |
3 files changed, 13 insertions, 14 deletions
diff --git a/sound/mips/Kconfig b/sound/mips/Kconfig index 8a33402fd415..b497b803c834 100644 --- a/sound/mips/Kconfig +++ b/sound/mips/Kconfig @@ -14,15 +14,15 @@ config SND_SGI_O2 tristate "SGI O2 Audio" depends on SGI_IP32 select SND_PCM - help - Sound support for the SGI O2 Workstation. + help + Sound support for the SGI O2 Workstation. config SND_SGI_HAL2 - tristate "SGI HAL2 Audio" - depends on SGI_HAS_HAL2 + tristate "SGI HAL2 Audio" + depends on SGI_HAS_HAL2 select SND_PCM - help - Sound support for the SGI Indy and Indigo2 Workstation. + help + Sound support for the SGI Indy and Indigo2 Workstation. endif # SND_MIPS diff --git a/sound/mips/hal2.c b/sound/mips/hal2.c index 6676bcbd769f..c9e060939708 100644 --- a/sound/mips/hal2.c +++ b/sound/mips/hal2.c @@ -741,8 +741,7 @@ static int hal2_pcm_create(struct snd_hal2 *hal2) snd_pcm_set_ops(pcm, SNDRV_PCM_STREAM_CAPTURE, &hal2_capture_ops); snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_CONTINUOUS, - snd_dma_continuous_data(GFP_KERNEL), - 0, 1024 * 1024); + NULL, 0, 1024 * 1024); return 0; } diff --git a/sound/mips/sgio2audio.c b/sound/mips/sgio2audio.c index fadc1194b136..9d20ce6118a0 100644 --- a/sound/mips/sgio2audio.c +++ b/sound/mips/sgio2audio.c @@ -582,14 +582,13 @@ static int snd_sgio2audio_pcm_close(struct snd_pcm_substream *substream) static int snd_sgio2audio_pcm_hw_params(struct snd_pcm_substream *substream, struct snd_pcm_hw_params *hw_params) { - return snd_pcm_lib_alloc_vmalloc_buffer(substream, - params_buffer_bytes(hw_params)); + return snd_pcm_lib_malloc_pages(substream, params_buffer_bytes(hw_params)); } /* hw_free callback */ static int snd_sgio2audio_pcm_hw_free(struct snd_pcm_substream *substream) { - return snd_pcm_lib_free_vmalloc_buffer(substream); + return snd_pcm_lib_free_pages(substream); } /* prepare callback */ @@ -670,7 +669,6 @@ static const struct snd_pcm_ops snd_sgio2audio_playback1_ops = { .prepare = snd_sgio2audio_pcm_prepare, .trigger = snd_sgio2audio_pcm_trigger, .pointer = snd_sgio2audio_pcm_pointer, - .page = snd_pcm_lib_get_vmalloc_page, }; static const struct snd_pcm_ops snd_sgio2audio_playback2_ops = { @@ -682,7 +680,6 @@ static const struct snd_pcm_ops snd_sgio2audio_playback2_ops = { .prepare = snd_sgio2audio_pcm_prepare, .trigger = snd_sgio2audio_pcm_trigger, .pointer = snd_sgio2audio_pcm_pointer, - .page = snd_pcm_lib_get_vmalloc_page, }; static const struct snd_pcm_ops snd_sgio2audio_capture_ops = { @@ -694,7 +691,6 @@ static const struct snd_pcm_ops snd_sgio2audio_capture_ops = { .prepare = snd_sgio2audio_pcm_prepare, .trigger = snd_sgio2audio_pcm_trigger, .pointer = snd_sgio2audio_pcm_pointer, - .page = snd_pcm_lib_get_vmalloc_page, }; /* @@ -720,6 +716,8 @@ static int snd_sgio2audio_new_pcm(struct snd_sgio2audio *chip) &snd_sgio2audio_playback1_ops); snd_pcm_set_ops(pcm, SNDRV_PCM_STREAM_CAPTURE, &snd_sgio2audio_capture_ops); + snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_VMALLOC, + NULL, 0, 0); /* create second pcm device with one outputs and no input */ err = snd_pcm_new(chip->card, "SGI O2 Audio", 1, 1, 0, &pcm); @@ -732,6 +730,8 @@ static int snd_sgio2audio_new_pcm(struct snd_sgio2audio *chip) /* set operators */ snd_pcm_set_ops(pcm, SNDRV_PCM_STREAM_PLAYBACK, &snd_sgio2audio_playback2_ops); + snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_VMALLOC, + NULL, 0, 0); return 0; } |