* [PATCH] ASoC: soc-pcm: fix the return value in dpcm_apply_symmetry()
@ 2021-06-14 7:17 Jaroslav Kysela
2021-06-14 19:53 ` Mark Brown
0 siblings, 1 reply; 2+ messages in thread
From: Jaroslav Kysela @ 2021-06-14 7:17 UTC (permalink / raw)
To: ALSA development; +Cc: Takashi Iwai, Mark Brown, Kuninori Morimoto
In case, where the loops are not executed for a reason, the uninitialized
variable 'err' is returned to the caller. Make code fully predictible
and assign zero in the declaration.
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Cc: Mark Brown <broonie@kernel.org>
Cc: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
sound/soc/soc-pcm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c
index 8659089a87a0..46513bb97904 100644
--- a/sound/soc/soc-pcm.c
+++ b/sound/soc/soc-pcm.c
@@ -1700,7 +1700,7 @@ static int dpcm_apply_symmetry(struct snd_pcm_substream *fe_substream,
struct snd_soc_dpcm *dpcm;
struct snd_soc_pcm_runtime *fe = asoc_substream_to_rtd(fe_substream);
struct snd_soc_dai *fe_cpu_dai;
- int err;
+ int err = 0;
int i;
/* apply symmetry for FE */
--
2.30.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] ASoC: soc-pcm: fix the return value in dpcm_apply_symmetry()
2021-06-14 7:17 [PATCH] ASoC: soc-pcm: fix the return value in dpcm_apply_symmetry() Jaroslav Kysela
@ 2021-06-14 19:53 ` Mark Brown
0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2021-06-14 19:53 UTC (permalink / raw)
To: Jaroslav Kysela, ALSA development
Cc: Takashi Iwai, Mark Brown, Kuninori Morimoto
On Mon, 14 Jun 2021 09:17:46 +0200, Jaroslav Kysela wrote:
> In case, where the loops are not executed for a reason, the uninitialized
> variable 'err' is returned to the caller. Make code fully predictible
> and assign zero in the declaration.
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
Thanks!
[1/1] ASoC: soc-pcm: fix the return value in dpcm_apply_symmetry()
commit: 12ffd726824a2f52486f72338b6fd3244b512959
All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying
to this mail.
Thanks,
Mark
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-06-14 20:01 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-14 7:17 [PATCH] ASoC: soc-pcm: fix the return value in dpcm_apply_symmetry() Jaroslav Kysela
2021-06-14 19:53 ` Mark Brown
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).