Re: [PATCH 2/4] ASoC: s3c24xx 8 bit sound fix

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Nov 12, 2008 at 11:55:47AM +0000, Mark Brown wrote:
> From: Christian Pellegrin <chripell@xxxxxxxxx>
> 
> fixes playing/recording of 8 bit audio files.
> 
> Generated on  20081108  against v2.6.27
> 
> Signed-off-by: Christian Pellegrin <chripell@xxxxxxxx>
> Signed-off-by: Mark Brown <broonie@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
> ---
>  sound/soc/s3c24xx/s3c24xx-i2s.c |    7 +++++++
>  1 files changed, 7 insertions(+), 0 deletions(-)
> 
> diff --git a/sound/soc/s3c24xx/s3c24xx-i2s.c b/sound/soc/s3c24xx/s3c24xx-i2s.c
> index ba4476b..c18977b 100644
> --- a/sound/soc/s3c24xx/s3c24xx-i2s.c
> +++ b/sound/soc/s3c24xx/s3c24xx-i2s.c
> @@ -261,10 +261,17 @@ static int s3c24xx_i2s_hw_params(struct snd_pcm_substream *substream,
>  
>  	switch (params_format(params)) {
>  	case SNDRV_PCM_FORMAT_S8:
> +		iismod &= ~S3C2410_IISMOD_16BIT;
> +		((struct s3c24xx_pcm_dma_params *)
> +		  rtd->dai->cpu_dai->dma_data)->dma_size = 1;
>  		break;
>  	case SNDRV_PCM_FORMAT_S16_LE:
>  		iismod |= S3C2410_IISMOD_16BIT;
> +		((struct s3c24xx_pcm_dma_params *)
> +		  rtd->dai->cpu_dai->dma_data)->dma_size = 2;
>  		break;
> +	default:
> +		return -EINVAL;
>  	}

Is playing with the dma parameters like that the correct way?
  
>  	writel(iismod, s3c24xx_i2s.regs + S3C2410_IISMOD);
> -- 
> 1.5.6.5
> 
> _______________________________________________
> Alsa-devel mailing list
> Alsa-devel@xxxxxxxxxxxxxxxx
> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

-- 
-- 
Ben

Q:      What's a light-year?
A:      One-third less calories than a regular year.

_______________________________________________
Alsa-devel mailing list
Alsa-devel@xxxxxxxxxxxxxxxx
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux