lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20240906103727.222749-1-usama.anjum@collabora.com>
Date: Fri,  6 Sep 2024 15:37:24 +0500
From: Muhammad Usama Anjum <usama.anjum@...labora.com>
To: Liam Girdwood <lgirdwood@...il.com>,
	Mark Brown <broonie@...nel.org>,
	Jaroslav Kysela <perex@...ex.cz>,
	Takashi Iwai <tiwai@...e.com>,
	Venkata Prasad Potturu <venkataprasad.potturu@....com>,
	Syed Saba Kareem <Syed.SabaKareem@....com>,
	Vijendar Mukunda <Vijendar.Mukunda@....com>,
	Muhammad Usama Anjum <usama.anjum@...labora.com>
Cc: kernel@...labora.com,
	linux-sound@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: [PATCH] ASoC: amd: acp: Return in-case of error

Return when error occurs instead of proceeding to for loop which will
use val uninitialized.

Fixes: f6f7d25b1103 ("ASoC: amd: acp: Add pte configuration for ACP7.0 platform")
Signed-off-by: Muhammad Usama Anjum <usama.anjum@...labora.com>
---
The fix may be wrong. Please consider this patch as report and fix it.
---
 sound/soc/amd/acp/acp-platform.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/amd/acp/acp-platform.c b/sound/soc/amd/acp/acp-platform.c
index ae63b2e693ab5..3a7a467b70633 100644
--- a/sound/soc/amd/acp/acp-platform.c
+++ b/sound/soc/amd/acp/acp-platform.c
@@ -231,7 +231,7 @@ void config_acp_dma(struct acp_dev_data *adata, struct acp_stream *stream, int s
 			break;
 		default:
 			dev_err(adata->dev, "Invalid dai id %x\n", stream->dai_id);
-			break;
+			return;
 		}
 		break;
 	default:
-- 
2.39.2


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ