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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20260126235018.969140-1-val@packett.cool>
Date: Mon, 26 Jan 2026 20:44:02 -0300
From: Val Packett <val@...kett.cool>
To: Bjorn Andersson <andersson@...nel.org>,
	Mathieu Poirier <mathieu.poirier@...aro.org>,
	Nathan Chancellor <nathan@...nel.org>,
	Nick Desaulniers <nick.desaulniers+lkml@...il.com>,
	Bill Wendling <morbo@...gle.com>,
	Justin Stitt <justinstitt@...gle.com>,
	Matti Lehtimäki <matti.lehtimaki@...il.com>,
	Luca Weiss <luca@...aweiss.eu>
Cc: Val Packett <val@...kett.cool>,
	Vladimir Lypak <vladimir.lypak@...il.com>,
	Barnabás Czémán <barnabas.czeman@...nlining.org>,
	Konrad Dybcio <konrad.dybcio@....qualcomm.com>,
	Dmitry Baryshkov <dmitry.baryshkov@....qualcomm.com>,
	~postmarketos/upstreaming@...ts.sr.ht,
	linux@...nlining.org,
	phone-devel@...r.kernel.org,
	linux-arm-msm@...r.kernel.org,
	devicetree@...r.kernel.org,
	linux-kernel@...r.kernel.org,
	linux-remoteproc@...r.kernel.org,
	llvm@...ts.linux.dev
Subject: [PATCH] remoteproc: qcom_wcnss: Fix handling the lack of PD regulators in v3

The changes introduced to handle single power domain platforms have
swapped the info pointer increment from num_pd_vregs to num_pds, which
doesn't change anything for pronto-v1 and v2 where they match, but as
pronto-v3 has 2 power domains with no PD regulators at all, this would
shift the pointer past the end of the array.

This showed up as a difference between GCC- and LLVM-compiled kernels
on MSM8953/SDM632 devices, where only with LLVM one would get the
"regulator request with no identifier" error, because the out-of-bounds
memory ended up being zeroed. Fix by reverting that single line.

Fixes: 65991ea8a6d1 ("remoteproc: qcom_wcnss: Handle platforms with only single power domain")
Signed-off-by: Val Packett <val@...kett.cool>
---

I'm like 99% sure that this (old) line is correct and the change in this one line
in 65991ea8a6d1 might've been an unintentional/stray one.

Still, please retest on MSM8974/MSM8226!

Thanks,
~val
---
 drivers/remoteproc/qcom_wcnss.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/remoteproc/qcom_wcnss.c b/drivers/remoteproc/qcom_wcnss.c
index ee18bf2e8054..5884c5a52af6 100644
--- a/drivers/remoteproc/qcom_wcnss.c
+++ b/drivers/remoteproc/qcom_wcnss.c
@@ -454,7 +454,7 @@ static int wcnss_init_regulators(struct qcom_wcnss *wcnss,
 	 * reserve extra space to manage them through the regulator interface.
 	 */
 	if (wcnss->num_pds) {
-		info += wcnss->num_pds;
+		info += num_pd_vregs;
 		/* Handle single power domain case */
 		if (wcnss->num_pds < num_pd_vregs)
 			num_vregs += num_pd_vregs - wcnss->num_pds;
-- 
2.51.2


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ