From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id B5713C25B74 for ; Tue, 21 May 2024 19:22:10 +0000 (UTC) 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-Owner; bh=wBfgmW6quEEcGSmjP6JRoiDyUeu18MvbxVs1Y4QrCgw=; b=X2cTrEX/gsggkjxwIEN3H/DZ/9 /6rfCS4RnxhiWF5DG799HBjHIhBJzh2kwclKFjD0NfqRgkxuuEWimqlITVOT+TjNkXzYYcR/LGntL fTk6HdoLqyqO8PXN11UVLKHW+Ov8cjTsQzmcEQoKX04wQv84mt/y876YAkwrlRYqmC77rurwcABlB y81tJhs30RE4eC+cVdTAQ/GSZo08fj4Zzz8M8vs6xjY4+bHwBzTz0EPrEZ/3fIfggwBeO1suD/XKf LfayrmAX53G7uENU/VEuhsCQ70BOSJ1z7k0IfOIvA/iBhH+LhQTo57ScDenlgbeY+S85N/hT7jLtK LcMk7jFA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1s9V3f-00000000tWP-2RXb; Tue, 21 May 2024 19:21:59 +0000 Received: from sin.source.kernel.org ([2604:1380:40e1:4800::1]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1s9V3c-00000000tVv-1k4H for linux-arm-kernel@lists.infradead.org; Tue, 21 May 2024 19:21:58 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by sin.source.kernel.org (Postfix) with ESMTP id 312E4CE10A6; Tue, 21 May 2024 19:21:53 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E6ED8C2BD11; Tue, 21 May 2024 19:21:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1716319312; bh=u6RvWRROhtl8idk8uNRbZmqRVPX4mzXHvZU6/iUf/SE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=OcDVqhZLUolUP9TGlRGcvy9J2HsxqD2CE8Sei9WCiZoXlfQFmXcf4YWevNewmLb94 jErEgGI6YwcDnE4+fCJP8Soap3ehqq1SuJWEcy0enUlJgjWy4mrKhe0jCfq2rW3oil 378tx4gYEtVG0qTkwdgsv7n3Cbn6R+VR/IAOM5lrvNbNMM0YLDZ02G4NjRiuCfL787 l3fMAhDSZ7vivzdOhxp+Y7l+XE1/PCBvPDJKem8Qizpaufyeugi5QCw7hgvzw2qAVq Kf4i2tFN716yOjC8j71KMnrDfOgYXVxR3hjLUIQbweJq0g3LZWP2HRpFEyuOMzo4iW 0Y/ybLyqyah7A== Date: Tue, 21 May 2024 20:21:45 +0100 From: Conor Dooley To: Elliot Berman Cc: Rob Herring , Frank Rowand , Krzysztof Kozlowski , Conor Dooley , Bjorn Andersson , Konrad Dybcio , Amrit Anand , Peter Griffin , Caleb Connolly , Andy Gross , Doug Anderson , Simon Glass , Chen-Yu Tsai , Julius Werner , "Humphreys, Jonathan" , Sumit Garg , Jon Hunter , Michal Simek , boot-architecture@lists.linaro.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org Subject: Re: [PATCH RFC v3 2/9] dt-bindings: board: Introduce board-id Message-ID: <20240521-bonfire-backboned-9ef33c10d447@spud> References: <20240521-board-ids-v3-0-e6c71d05f4d2@quicinc.com> <20240521-board-ids-v3-2-e6c71d05f4d2@quicinc.com> MIME-Version: 1.0 In-Reply-To: <20240521-board-ids-v3-2-e6c71d05f4d2@quicinc.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240521_122156_865009_CB3F61D5 X-CRM114-Status: GOOD ( 22.96 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: multipart/mixed; boundary="===============8400956700331207557==" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org --===============8400956700331207557== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="uf6VAPW/MlC6Q9tN" Content-Disposition: inline --uf6VAPW/MlC6Q9tN Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, May 21, 2024 at 11:37:59AM -0700, Elliot Berman wrote: > Device manufcturers frequently ship multiple boards or SKUs under a > single softwre package. These software packages ship multiple devicetree > blobs and require some mechanims to pick the correct DTB for the boards > that use the software package. Okay, you've got the problem statement here, nice. > This patch introduces a common language > for adding board identifiers to devicetrees. But then a completely useless remainder of the commit message. I open this patch, see the regexes, say "wtf", look at the commit message and there is absolutely no explanation of what these properties are for. That's quite frankly just not good enough - even for an RFC. >=20 > Signed-off-by: Elliot Berman > --- > .../devicetree/bindings/board/board-id.yaml | 24 ++++++++++++++++= ++++++ > 1 file changed, 24 insertions(+) >=20 > diff --git a/Documentation/devicetree/bindings/board/board-id.yaml b/Docu= mentation/devicetree/bindings/board/board-id.yaml > new file mode 100644 > index 000000000000..99514aef9718 > --- /dev/null > +++ b/Documentation/devicetree/bindings/board/board-id.yaml > @@ -0,0 +1,24 @@ > +# SPDX-License-Identifier: BSD-2-Clause > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/board/board-id.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: board identifiers > +description: Common property for board-id subnode s/property/properties/ > + > +maintainers: > + - Elliot Berman > + > +properties: > + $nodename: > + const: '/' > + board-id: > + type: object > + patternProperties: > + "^.*(?!_str)$": Does this regex even work? Take "foo_str" as an example - doesn't "^.*" consume all of the string, leaving the negative lookahead with nothing to object to? I didn't properly test this with an example and the dt tooling, but I lazily threw it into regex101 and both the python and emcascript versions agree with me. Did you test this? And while I am here, no underscores in property names please. And if "str" means string, I suggest not saving 3 characters. > + $ref: /schemas/types.yaml#/definitions/uint32-matrix > + "^.*_str$": > + $ref: /schemas/types.yaml#/definitions/string-array Why do we even need two methods? Commit message tells me nothing and there's no description at all... Why do we need regexes here, rather than explicitly defined properties? Your commit message should explain the justification for that and the property descriptions (as comments if needs be for patternProperties) should explain why this is intended to be used. How is anyone supposed to look at this binding and understand how it should be used? Utterly lost, Conor. --uf6VAPW/MlC6Q9tN Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCZkz0SQAKCRB4tDGHoIJi 0njSAP9bS2FNXcU4nqFnmSCUKGplVQ/vSymPzzigumsrEX1WDwD/XIWhiLbRxeax Ppm78ZkTr4oulTO08z+CHSV95+T75A8= =d9SL -----END PGP SIGNATURE----- --uf6VAPW/MlC6Q9tN-- --===============8400956700331207557== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --===============8400956700331207557==--