From: Takashi Iwai Date: Mon, 4 Feb 2019 15:40:55 +0000 (+0100) Subject: ASoC: uniphier: Drop superfluous PCM preallocation error checks X-Git-Tag: v5.4-rc1~1151^2~71^2~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c87592fec3963c8f7f95db866cb260cee48d76a3;p=platform%2Fkernel%2Flinux-rpi.git ASoC: uniphier: Drop superfluous PCM preallocation error checks snd_pcm_lib_preallocate_pages() and co always succeed, so the error check is simply redundant. Drop it. Reviewed-by: Jaroslav Kysela Acked-by: Mark Brown Signed-off-by: Takashi Iwai --- diff --git a/sound/soc/uniphier/aio-dma.c b/sound/soc/uniphier/aio-dma.c index 4ec6b65..fa001d3 100644 --- a/sound/soc/uniphier/aio-dma.c +++ b/sound/soc/uniphier/aio-dma.c @@ -235,10 +235,11 @@ static int uniphier_aiodma_new(struct snd_soc_pcm_runtime *rtd) if (ret) return ret; - return snd_pcm_lib_preallocate_pages_for_all(pcm, + snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_DEV, dev, uniphier_aiodma_hw.buffer_bytes_max, uniphier_aiodma_hw.buffer_bytes_max); + return 0; } static void uniphier_aiodma_free(struct snd_pcm *pcm)