From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796074612; b=rMnm0aKXi6nTDyqpBj0olfA083uJbyokosUXeaO4PXcJ7jjV+Se6jm6bbunPRd888uc8 Sx6KRicLGO9akIJgbKyp2xdDQecsazN+P2tMjrZh1pzrCxST5+aIwcpijl/2ZvCcUMBLo qmnAbJgFaObb9KqAWo0ts60sAQ8pJcTQyFSbVIRcj2vNv/NKTqLW6dEl47uN3QzbvB0cS 50iNYOlO1Vo+48dCWVqGvB8tJ9HTgVBwVxpvxCO0RflqGbjWEOygRjye1S8BGRuDyVV2d IcJHJuBWhz9CTCkBolsCM5X4F5jxOLASNtpxai24Pf4j1cz/KwWEfF8dg/U80Eln1sA== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796074612; h=Received:DKIM-Signature:Message-ID:From:Subject:Reply-To:To:Cc: In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date; bh=zwrYJIrd85cUlpeiyVY+OmQgeBFoTg10HcWJcV4Elbs=; b=f/N3Ikeylp51TuOu27TOCVSR9dogti+2Jv7SVLIvMkJ7Uxek97y++jUtvrpNp0iolzNE 2Jx9Yw/T5iZCV8ICvMrfKdDTrKyH4xkg/yoiRsSV9a2ABE8FZ2Tq6Hk0eqzNWCXqbpFAd Jx/zBpGMm8CqXZEHBwX0ov4SHS+OZHegzD7CCECVlBJ5EjGTVd4qTzo2T/fLkAkPEFG41 pVJ6eEARSIVE5rgfph0b9+80WCeg0VvtCCTwtqCenrZ8IEwLM09vfKWAi1QE3/oe2LLix HuJogdiJR4/oLYZ1v5CBPGJSd3t5VIGFE/MAGfpbCtposyd7wEkdwJ4kxMGqdvCojjg== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=hR2OuuCK; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 74E9B606A329; Mon, 30 Nov 2026 21:36:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=hR2OuuCK Received: by smtp.kernel.org (Postfix) with ESMTPSA id CA4D51F0092C; Mon, 30 Nov 2026 21:36:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796074612; bh=zwrYJIrd85cUlpeiyVY+OmQgeBFoTg10HcWJcV4Elbs=; h=From:Subject:Reply-To:To:Cc:In-Reply-To:References:Date; b=hR2OuuCK0GHWkIbsggxTNKn2zAY9bH+d8iBbMDn71R2UbcaZKhwiU9T3tRETBn7E+ WDZPgIhxZRmc7ebU0I1ZGjOVD0hKjHXj8cnSKb4RqRee9s8v1EkHatF0I+/iGUy/TO BTfkKnIQy8vCP9pkW9KQMn+DUGqSGyycAux9jwngCliiF2ZcqM5XszOMyWNlqhdJnV w+o1aYYao/J6F9zMW5bb5brNkvZ7CpR9y0UNYlwxh0QHh5Jxcion6d7wMZqyyRxn8c AyarFqyNxAjIv/AzkKD66ypNj3ias1ftZMB4Bv9aieZjszuDWGMFTXtGOBZyTpMVbd PAlOo+PWuv4AA== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH v3 07/24] ASoC: codecs: wsa883x: add VI sense capture DAI Reply-To: sashiko-reviews@lists.linux.dev To: "Srinivas Kandagatla" Cc: linux-sound@vger.kernel.org, devicetree@vger.kernel.org, robh@kernel.org, conor+dt@kernel.org In-Reply-To: <20261130212258.7376-8-srinivas.kandagatla@oss.qualcomm.com> References: <20261130212258.7376-1-srinivas.kandagatla@oss.qualcomm.com> <20261130212258.7376-8-srinivas.kandagatla@oss.qualcomm.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Mon, 30 Nov 2026 21:36:51 +0000 X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list Thank you for your contribution! Sashiko AI review found 1 potential issue to consider: - [Medium] ASoC: codecs: wsa883x: missing port_enable check in wsa883x_vi_hw_params() -- commit da1918f2dca4e2889b9a754a96cbf9f3750c03ce Author: Ravi Hothi ASoC: codecs: wsa883x: add VI sense capture DAI This commit moves the VISENSE port to the SoundWire source port mask, adds a dedicated VI capture DAI and stream runtime, and implements a bus_config callback for WSA883x. > diff --git a/sound/soc/codecs/wsa883x.c b/sound/soc/codecs/wsa883x.c > index 64391d654a08b..6de669288d6aa 100644 > --- a/sound/soc/codecs/wsa883x.c > +++ b/sound/soc/codecs/wsa883x.c [ ... ] > @@ -1335,6 +1351,25 @@ static const struct snd_soc_component_driver wsa88= 3x_component_drv =3D { > .num_dapm_routes =3D ARRAY_SIZE(wsa883x_audio_map), > }; > =20 > +static int wsa883x_vi_hw_params(struct snd_pcm_substream *substream, > + struct snd_pcm_hw_params *params, > + struct snd_soc_dai *dai) > +{ > + struct wsa883x_priv *wsa883x =3D dev_get_drvdata(dai->dev); > + > + wsa883x->vi_port_config =3D wsa883x_pconfig[WSA883X_PORT_VISENSE]; > + wsa883x->vi_sconfig.frame_rate =3D params_rate(params); > + /* VISENSE carries the V and I sense pair */ > + wsa883x->vi_sconfig.ch_count =3D 2; > + wsa883x->vi_sconfig.bps =3D 1; > + wsa883x->vi_sconfig.type =3D SDW_STREAM_PDM; > + wsa883x->vi_sconfig.direction =3D SDW_DATA_DIR_TX; > + > + return sdw_stream_add_slave(wsa883x->slave, &wsa883x->vi_sconfig, > + &wsa883x->vi_port_config, 1, > + wsa883x->vi_sruntime); > +} > + > static int wsa883x_hw_params(struct snd_pcm_substream *substream, > struct snd_pcm_hw_params *params, > struct snd_soc_dai *dai) > @@ -1344,6 +1379,9 @@ static int wsa883x_hw_params(struct snd_pcm_substre= am *substream, > =20 > wsa883x->active_ports =3D 0; > for (i =3D 0; i < WSA883X_MAX_SWR_PORTS; i++) { > + /* VISENSE is driven by the separate VI capture DAI */ > + if (i =3D=3D WSA883X_PORT_VISENSE) > + continue; > if (!wsa883x->port_enable[i]) > continue; [Severity: Medium] Should wsa883x_vi_hw_params() return early when wsa883x->port_enable[WSA883X_PORT_VISENSE] is false, as wsa884x_vi_hw_params() does? Because wsa883x_hw_params() now skips WSA883X_PORT_VISENSE, nothing checks port_enable[WSA883X_PORT_VISENSE] during stream setup. The "VISENSE Switch" mixer control becomes a no-op, and sdw_stream_add_slave() always registers the VISENSE port and transitions vi_sruntime out of SDW_STREAM_ALLOCATED, causing qcom_snd_sdw_prepare() to prepare and enable the VI capture stream on the SoundWire bus even when VI sensing is turned off. --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261130212258.7376= -1-srinivas.kandagatla@oss.qualcomm.com?part=3D7