From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E76E5606A327 for ; Mon, 30 Nov 2026 13:42:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=rKnko27b; dkim=fail reason="signature verification failed" (2048-bit key) header.d=baylibre.com header.i=@baylibre.com header.a=rsa-sha256 header.s=google header.b=lrrCm/z1 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:Content-Type: List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: In-Reply-To:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date :Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Unsubscribe-Post:List-Owner; bh=LRdvixsVtoDBF++o0IVSTmTZOeV0dn8ZDbZA36Ux2to=; b=rKnko27brjkWpOfBI46jHg3pKL RhyOlrfhgemcZ1IUMpbpfai2UbvYJVF2lyU2IwjPSbpy+yV2Jc1CJUFdRJT74muZ9DP0unW9gicQY WytQjJcYBY/T/ASDYNbvN7uB4mmrN29lRIlxA+/WOSG1sFuoXV7R/tRBBtx+/EX6awcB6uJIPlCUz 1itSeWX2hVrm4o7J3CjNd3iYxYT3Yns6rW4HB6YLZPavLmIS0In9OHS36Ra1DVbhePnXvNShAAitr sY/+YTHYBM1USJdB++FfwxwD1wpr6Wz0wldDFuMQHmgRMpUd3Nx7W8u+ZoHNZ7qIRrr4IAjl4o/Iq fFHUeQuw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.100.1 #2 (Red Hat Linux)) id 1xY1e5-00000004kLs-1MQM; Mon, 30 Nov 2026 13:42:18 +0000 Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]) by bombadil.infradead.org with esmtps (Exim 4.100.1 #2 (Red Hat Linux)) id 1xY1e1-00000004kL5-0X01 for linux-amlogic@lists.infradead.org; Mon, 30 Nov 2026 13:42:15 +0000 Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-4bb702a7548so95424215e9.1 for ; Mon, 30 Nov 2026 05:42:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre.com; s=google; t=1796046131; x=1796650931; darn=lists.infradead.org; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:from:to:cc:subject :date:message-id:reply-to:content-type; bh=NDPdUVsPVVjZ+RumeQAR9JM8mRkQx5O9QgoQ04DlkZc=; b=lrrCm/z1wG1ab36CLVUrwrRLLEAu1//NHOhTi58cyD//s2Gg9ZjIRi0eW9p6Pu6699 mGCn/J4eCY6u7ut+/PTE8Cj+PmNADkaKXJ+AywfTtA7ubG15hkPodEwiPrEx79tgRtH7 Cj+z8tbPCIe0BKDQqcFiVxXwQFdt8gWle0vp55HDNOlxles8nMvB5NJXMPYb+bgIJ4sc M+vvInPxQ8tuNiZcdPGc1H/+uIZHgDJ0XDQZ3NKFCWfeY5rGoISNWuGzhiOxqe6DJiF9 C88CShiUd4KFrhJ+a/DoG9VYOhYYnwpKXKzY50Cr+F75+6cGUAqMRwYtfoWsStncHcnM jJHQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796046131; x=1796650931; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=NDPdUVsPVVjZ+RumeQAR9JM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Joagk 9J8ejQKXqUBlOrWZwucMExoEaAF3DkukDW56jx9Ftk+fmFeZoUN5txVZjoKyabm189LWH7XVYSL wFW16zGR0jIV+ctDxwGVToIZrRHmP2Dityz1vUnkfUn57qz7euewN7oTReMXcF8hlqVqUDpzlWj UHLtDs2oUK24qlsX4tD5Fn/3snlV0XUct3onyThGGqF8W2HiNnOi1eCd X-Received: by 2002:a05:600c:8b11:b0:4bb:6871:8f21 with SMTP id 5b1f17b1804b1-4bb88822346mr690714125e9.23.1796046130783; Mon, 30 Nov 2026 05:42:10 -0800 (PST) Received: from localhost ([2a02:8071:6e30:8500:1d24:d58d:2b65:c291]) by smtp.gmail.com with UTF8SMTPSA id 5b1f17b1804b1-4bb884ab091sm1276073375e9.11.2026.11.30.05.42.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Nov 2026 05:42:09 -0800 (PST) Date: Mon, 30 Nov 2026 14:42:07 +0100 From: Uwe =?utf-8?Q?Kleine-K=C3=B6nig?= To: sashiko-reviews@lists.linux.dev Cc: Xianwei Zhao , devicetree@vger.kernel.org, linux-amlogic@lists.infradead.org, robh@kernel.org, conor+dt@kernel.org, neil.armstrong@linaro.org Subject: Re: [PATCH v5 2/3] pwm: meson: add the PWM count driver data Message-ID: References: <20261130-s6-s7-pwm-v5-0-396935d2987d@amlogic.com> <20261130-s6-s7-pwm-v5-2-396935d2987d@amlogic.com> X-Archived-By: MIME-Version: 1.0 In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.9.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20261130_054213_194965_F4D31F24 X-CRM114-Status: GOOD ( 26.89 ) X-Spam-Score: -2.1 (--) X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: multipart/mixed; boundary="===============2883485673132534257==" Sender: "linux-amlogic" X-Spam-Status: No, score=-13.9 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 --===============2883485673132534257== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="twdgoaob2gzzvdxz" Content-Disposition: inline --twdgoaob2gzzvdxz Content-Type: text/plain; protected-headers=v1; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Subject: Re: [PATCH v5 2/3] pwm: meson: add the PWM count driver data MIME-Version: 1.0 On Mon, Nov 30, 2026 at 12:06:44PM +0000, sashiko-bot@kernel.org wrote: > Thank you for your contribution! Sashiko AI review found 2 potential > issues to consider: > - [Low] pwm: meson: unreplaced XYZ placeholder and incomplete commit > message > - [Low] pwm: meson: unaddressed v4 feedback on MESON_NUM_PWMS and XYZ > placeholder > -- >=20 > commit dc63cdb88cc6bfabf5cc70eb8f664cded9a113d3 > Author: Xianwei Zhao >=20 > > pwm: meson: add the PWM count driver data > > > > To prepare adding support for XYZ which doesn't have 2 but 1 > > PWM outputs, make the various loops iterater using chip->npwm > > instead of the constant MESON_NUM_PWMS. > > > > Reviewed-by: Alexandre Mergnat > > Signed-off-by: Xianwei Zhao >=20 > [Severity: Low] > The commit message still contains the literal placeholder "XYZ" instead of > naming the target Amlogic SoCs (S6, S7 and S7D) and has a typo in > "iterater". It also omits that this patch adds npwm to struct > meson_pwm_data, sets .npwm =3D 2 for existing variants, and passes > pdata->npwm to devm_pwmchip_alloc() in meson_pwm_probe(). The typo is mine, please still fix it :-) > > diff --git a/drivers/pwm/pwm-meson.c b/drivers/pwm/pwm-meson.c > > index 3a28c853089f8..422aa8bb20b44 100644 > > --- a/drivers/pwm/pwm-meson.c > > +++ b/drivers/pwm/pwm-meson.c > > @@ -108,6 +108,7 @@ struct meson_pwm_data { > > int (*channels_init)(struct pwm_chip *chip); > > bool has_constant; > > bool has_polarity; > > + u8 npwm; > > }; > > =20 > > struct meson_pwm { > > @@ -440,7 +441,7 @@ static int meson_pwm_init_clocks_meson8b(struct pwm= _chip *chip, > > char name[255]; > > int err; > > =20 > > - for (i =3D 0; i < MESON_NUM_PWMS; i++) { > > + for (i =3D 0; i < chip->npwm; i++) { >=20 > [ ... ] >=20 > > @@ -699,9 +710,10 @@ static int meson_pwm_probe(struct platform_device = *pdev) > > { > > struct pwm_chip *chip; > > struct meson_pwm *meson; > > + const struct meson_pwm_data *pdata =3D of_device_get_match_data(&pdev= ->dev); > > int err; > > =20 > > - chip =3D devm_pwmchip_alloc(&pdev->dev, MESON_NUM_PWMS, sizeof(*meson= )); > > + chip =3D devm_pwmchip_alloc(&pdev->dev, pdata->npwm, sizeof(*meson)); >=20 > [Severity: Low] > As reported by Uwe Kleine-K=F6nig on v4 [1], can MESON_NUM_PWMS be droppe= d in > this commit now that the channel count comes from pdata->npwm? > drivers/pwm/pwm-meson.c still defines MESON_NUM_PWMS to size > meson_pwm_per_channel_data[] and meson->channels[]. >=20 > [1] https://lore.kernel.org/r/aw01OAIy4gGjXvDI@monoceros Oh wow, I didn't know that Sashiko refers to other reviews. That's strong. I guess that means trouble if npwm > 2, this is exactly the failure I had in mind when I asked for dropping MESON_NUM_PWMS. Maybe add an assert (BUG_ON?) to catch that? Best regards Uwe --twdgoaob2gzzvdxz Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEP4GsaTp6HlmJrf7Tj4D7WH0S/k4FAmsNfS0ACgkQj4D7WH0S /k5m3Af/dbyv3rn5JoIsktE2jo2soY2XPyTDHqJFf4r9+uaN3amQy9synIPsbpiu ObrJTbr61u3FjB0U7B/4Z3yLp3N7zcVeTMVqGHuxWcIqZdNacv3ZR9Sb21s0G6mZ Po094+KgnHxOC/UGJPLQLY+QEPxWcCfz4Fqyeq3NpMcsuZmm7AYmW5a6yos9TgCM Ec8b5W/J8ZC6PmgOCwMfcV6/Qt+tjmGartG3szAjbYMYZLmjEtgl8TFbKTMyAd/e 7mbBcBhhyGg5k036tbHf4TvPB6lK3lYmB2uRYWx6zDfr0bDh96AuELH9/+Rs/bAE 1A3rvWgpwR0XjVN+VjqS+XrHZI8x5Q== =F2jh -----END PGP SIGNATURE----- --twdgoaob2gzzvdxz-- --===============2883485673132534257== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-amlogic mailing list linux-amlogic@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-amlogic --===============2883485673132534257==--