[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87mv2tix83.wl%kuninori.morimoto.gx@renesas.com>
Date: Fri, 8 Dec 2017 06:00:22 +0000
From: Kuninori Morimoto <kuninori.morimoto.gx@...esas.com>
To: Jiada Wang <jiada_wang@...tor.com>
Cc: <lgirdwood@...il.com>, <broonie@...nel.org>, <perex@...ex.cz>,
<tiwai@...e.com>, <alsa-devel@...a-project.org>,
<linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v1 1/2] ASoC: rsnd: ssi: fix race condition in rsnd_ssi_pointer_update
Hi Jiada
> >> Currently there is race condition between set of byte_pos and wrap
> >> it around when new buffer starts. If .pointer is called in-between
> >> it will result in inconsistent pointer position be returned
> >> from .pointer callback.
> >>
> >> This patch increments buffer pointer atomically to avoid this issue.
> >>
> >> Signed-off-by: Jiada Wang<jiada_wang@...tor.com>
> >> Reviewed-by: Takashi Sakamoto<takashi.sakamoto@...aclelinux.com>
> >> ---
> > You using playback with PIO mode ?
> > Because this function is no longer used on DMA mode
> No, we are using rcar sound in DMA mode,
> our original patch resolves the issue in core.c for both PIO & DMA mode.
>
> but with your commit a97a06c ("ASoC: rsnd: cleanup pointer related code"),
> DMA mode no longer has the race condition issue,
> so I ported our fix patch to only address the issue in PIO mode
Thanks. Nice to know.
Best regards
---
Kuninori Morimoto
Powered by blists - more mailing lists