[alsa-devel] [PATCH] ASoC: S3C: Fix PCM RX FIFO settings
Seungwhan Youn
claude.youn at gmail.com
Thu Sep 9 03:47:50 CEST 2010
On Wed, Sep 8, 2010 at 6:48 PM, Jassi Brar <jassisinghbrar at gmail.com> wrote:
> On Wed, Sep 8, 2010 at 5:51 PM, Seungwhan Youn <sw.youn at samsung.com> wrote:
>> When PCM capture, sound recorded abnormally because of RX FIFO
>> threshold settings are missing. So, This patch modify PCM RX FIFO
>> setting codes same as TX.
>>
>> Signed-off-by: Seungwhan Youn <sw.youn at samsung.com>
>> ---
>> sound/soc/s3c24xx/s3c-pcm.c | 3 +++
>> sound/soc/s3c24xx/s3c-pcm.h | 3 ++-
>> 2 files changed, 5 insertions(+), 1 deletions(-)
>>
>> diff --git a/sound/soc/s3c24xx/s3c-pcm.c b/sound/soc/s3c24xx/s3c-pcm.c
>> index 43dcc6b..deaa3f2 100644
>> --- a/sound/soc/s3c24xx/s3c-pcm.c
>> +++ b/sound/soc/s3c24xx/s3c-pcm.c
>> @@ -107,11 +107,14 @@ static void s3c_pcm_snd_rxctrl(struct s3c_pcm_info *pcm, int on)
>>
>> ctl = readl(regs + S3C_PCM_CTL);
>> clkctl = readl(regs + S3C_PCM_CLKCTL);
>> + ctl &= ~(S3C_PCM_CTL_RXDIPSTICK_MASK
>> + << S3C_PCM_CTL_RXDIPSTICK_SHIFT);
>>
>> if (on) {
>> ctl |= S3C_PCM_CTL_RXDMA_EN;
>> ctl |= S3C_PCM_CTL_RXFIFO_EN;
>> ctl |= S3C_PCM_CTL_ENABLE;
>> + ctl |= (0x20<<S3C_PCM_CTL_RXDIPSTICK_SHIFT);
>
> Yes, the change is needed.
> But I think we should use small value as fifo_dipstick (maybe 0x4 ?), because
> Fifo is considered:-
> Almost_empty when fifo_depth < fifo_dipstick
> Almost_full when fifo_depth > (32 – fifo_dipstick)
Yes, you're right.
>
> And, please modify for TX as well.
>
I'll fix this fifo_dipstick value to be a suitable one and re-submit
with TX's fifo_dipstick.
Thanks for your opinion.
Claude.
More information about the Alsa-devel
mailing list