Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp3666350pxb; Mon, 16 Nov 2020 23:38:13 -0800 (PST) X-Google-Smtp-Source: ABdhPJwF3ZsKVaZjeekhnDqXgcoNg9ad1HHi3Ig1LoSzJMvofA6k6KYYJZSOq109ZQ0LTA2iQoSE X-Received: by 2002:a17:906:8603:: with SMTP id o3mr18241437ejx.333.1605598693011; Mon, 16 Nov 2020 23:38:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605598693; cv=none; d=google.com; s=arc-20160816; b=j6VQz5gqe2xm8XZDu8QU0L+gxU4Jy4g1aSlLBtlaLS3C0dZLgW+xjTl/bYCc0mSrMS upvPiCYf2Gdc/KgM67Rj3nKKHd9+nxUbvItqgazlOGSk6T8bGaaK/SwowLP/vJgRgD8G XQJpUvNOVev4Ibc1NMmQTbW16OEidJVq2olnIUFuJ/hNUjNjM1k4CCCm+Vj42ZuYm/Iz ZCwE5bOikmAEjVziNUBK0D7J9G63qIozP3vhSFMLNTDvpexU89QgMpeJCEdweUiT3+Py tr+Aed8Bco96CbV8Cu+uHhJvEdioV4hFRreLW1ATaYp4sya5JNVp1yPDrrBrEQoSRnOs kKEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=4+DTNjldknsbGbykrDi3KMc9iGQY2KJN88Az0UZ8q2k=; b=wZHiDDezWHRLmnjkYRuCmIhWN1U9wqBWY+0/L151tZs+0B/y0T/eo8P6uREFnaWhZT YD73fkRcyxShi7W94Lc4bhAcNv9UG4sryOpwk8v+mLwVKsngBqc9+ALqyOhsDW1kYoXU Roja8bY0DLuQBdQVautyw1DmhQ4GeBsP/sZIvUkfk97qmnTNtTE/0NOZoiTTXvhIJKgH SRqjp9ZwgN+fs4KawF6g5SvJhf0JsoqCzmABJOjlwhn2I1UKoK2BTQv6yjEG3piMamEd XV/NDvSZSl5w8lwdgdrYuHyenNV7ZoUKTlumEH9SSv97f5/fScX5DxWFeAKJpsYcYwM4 Kq2Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x64si14427647edc.367.2020.11.16.23.37.50; Mon, 16 Nov 2020 23:38:12 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726339AbgKQHgP convert rfc822-to-8bit (ORCPT + 99 others); Tue, 17 Nov 2020 02:36:15 -0500 Received: from mail-wm1-f68.google.com ([209.85.128.68]:40471 "EHLO mail-wm1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725771AbgKQHgO (ORCPT ); Tue, 17 Nov 2020 02:36:14 -0500 Received: by mail-wm1-f68.google.com with SMTP id a3so2249700wmb.5; Mon, 16 Nov 2020 23:36:13 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to; bh=9MPQ28eRVEZoeAfW6tqzwdTMKkuu3vxDE3zbTGm+kt8=; b=RhDYMHSxm6+CP4RZIuSvf4Z7yG7z7Yi3yvwnoqVq4PiLsGBY6goiYrEZjGiTx+CG/3 tGlPPw8xjf4xtAsKv414nsKXOLxNGQk9h7j59n7hFmK37Rs4nywSgKhwYrMGnI/CFO6Y BE4n0YkSZi90S9JNpHpvthLZl3eGsQSB+I5PDdOeGP9NnAJVuEQYiSihaDAAoDJFgBpc 3Hz5k2eWbbNCYa7EcA14KWRRaU07VT8t7InhXqGS8j1Dm2vsDe+7tfU1CupY91UWQP/Q VNMxLlUoFJntpmz+Ahn2ocF310fhZs/RPI2SHS6gvo1OdvIWkcKqlqW8XbCSM21CSddw 9s4w== X-Gm-Message-State: AOAM532L+xmqWhQhW/lL2KMLArIlOidJrxMt/0TaTPcX0ygluw3r2z8n VgWs14X9ct9GQ/nCmz+gAu4= X-Received: by 2002:a7b:c202:: with SMTP id x2mr2754290wmi.48.1605598572563; Mon, 16 Nov 2020 23:36:12 -0800 (PST) Received: from kozik-lap (adsl-84-226-167-205.adslplus.ch. [84.226.167.205]) by smtp.googlemail.com with ESMTPSA id 89sm27113016wrp.58.2020.11.16.23.36.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Nov 2020 23:36:11 -0800 (PST) Date: Tue, 17 Nov 2020 08:36:09 +0100 From: Krzysztof Kozlowski To: Alice Guo Cc: "robh+dt@kernel.org" , "shawnguo@kernel.org" , "s.hauer@pengutronix.de" , dl-linux-imx , Peng Fan , "devicetree@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" Subject: Re: [EXT] Re: [PATCH v3 1/4] dt-bindings: soc: imx8m: add DT Binding doc for soc unique ID Message-ID: <20201117073609.GA3436@kozik-lap> References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8BIT In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Nov 17, 2020 at 07:10:28AM +0000, Alice Guo wrote: > > > > -----Original Message----- > > From: Krzysztof Kozlowski > > Sent: 2020年11月17日 0:03 > > To: Alice Guo > > Cc: robh+dt@kernel.org; shawnguo@kernel.org; s.hauer@pengutronix.de; > > dl-linux-imx ; Peng Fan ; > > devicetree@vger.kernel.org; linux-kernel@vger.kernel.org; > > linux-arm-kernel@lists.infradead.org > > Subject: Re: [EXT] Re: [PATCH v3 1/4] dt-bindings: soc: imx8m: add DT Binding > > doc for soc unique ID > > > > Caution: EXT Email > > > > On Mon, Nov 16, 2020 at 07:04:13AM +0000, Alice Guo wrote: > > > > > > > -----Original Message----- > > > > From: Krzysztof Kozlowski > > > > Sent: 2020年11月15日 0:50 > > > > To: Alice Guo > > > > Cc: robh+dt@kernel.org; shawnguo@kernel.org; s.hauer@pengutronix.de; > > > > dl-linux-imx ; Peng Fan ; > > > > devicetree@vger.kernel.org; linux-kernel@vger.kernel.org; > > > > linux-arm-kernel@lists.infradead.org > > > > Subject: [EXT] Re: [PATCH v3 1/4] dt-bindings: soc: imx8m: add DT > > > > Binding doc for soc unique ID > > > > > > > > Caution: EXT Email > > > > > > > > On Fri, Nov 13, 2020 at 07:04:06PM +0800, Alice Guo wrote: > > > > > Add DT Binding doc for the Unique ID of i.MX 8M series. > > > > > > > > > > Signed-off-by: Alice Guo > > > > > --- > > > > > .../devicetree/bindings/arm/fsl.yaml | 25 > > > > +++++++++++++++++++ > > > > > 1 file changed, 25 insertions(+) > > > > > > > > > > diff --git a/Documentation/devicetree/bindings/arm/fsl.yaml > > > > > b/Documentation/devicetree/bindings/arm/fsl.yaml > > > > > index e4db0f9ed664..f4faebbb57da 100644 > > > > > --- a/Documentation/devicetree/bindings/arm/fsl.yaml > > > > > +++ b/Documentation/devicetree/bindings/arm/fsl.yaml > > > > > @@ -901,6 +901,31 @@ properties: > > > > > - fsl,s32v234-evb # S32V234-EVB2 > > Customer > > > > Evaluation Board > > > > > - const: fsl,s32v234 > > > > > > > > > > + soc: > > > > > + type: object > > > > > + properties: > > > > > + compatible: > > > > > + oneOf: > > > > > + - description: i.MX8M SoCs > > > > > + items: > > > > > + - enum: > > > > > + - fsl,imx8mm-soc > > > > > + - fsl,imx8mn-soc > > > > > + - fsl,imx8mp-soc > > > > > + - fsl,imx8mq-soc > > > > > + - const: simple-bus > > > > > + > > > > > + - description: Other SoCs > > > > > + items: > > > > > + - const: simple-bus > > > > > + > > > > > + nvmem-cells: > > > > > + maxItems: 1 > > > > > + description: Phandle to the SOC Unique ID provided by a > > > > > + nvmem node > > > > > + > > > > > + nvmem-cells-names: > > > > > + const: soc_unique_id > > > > > + > > > > > additionalProperties: true > > > > > > > > The "soc" node should be required for these compatibles. Otherwise > > > > you will have to stay with this > > > > backwards-compatible-DTB-device-initcall-glue for many years... I think you > > can achieve it with allOf. > > > > > > > [Alice Guo]Hi, > > > I find that my description for compatible is ambiguous. There are two kinds of > > compatible of the "soc" node: > > > 1. For dtsi files used for SoCs other than imx8m series SoCs and old > > > version dtsi files used for imx8m series SoCs, compatible of the "soc" node is > > "simple-bus". > > > 2. For new version dtsi files used for imx8m series SoCs, compatible of the > > "soc" node is {"fsl,imx8mX-soc","simple-bus"}. > > > > > > "nvmem-cell" is an optional property. > > > > > > I do not understand what you mean. You mean that limit the compatible of > > "soc" node must include " fsl,imx8mX-soc" in new version dts files. Is my > > understanding correct? > > > > All new DTS files should have soc node with "fsl,imx8mX-soc" and this should be > > required by dtschema. The nvmem-cells and related properties do not look like > > optional. From the hardware perspective - they are always present. From the > > driver point of view: they are required and driver will fail to work. > > [Alice Guo] > + soc: > + type: object > + properties: > + compatible: > + oneOf: > + - description: new version DTS for i.MX8M SoCs > + items: > + - enum: > + - fsl,imx8mm-soc > + - fsl,imx8mn-soc > + - fsl,imx8mp-soc > + - fsl,imx8mq-soc > + - const: simple-bus > + > + - description: other SoCs and old version DTS for i.MX8M SoCs > + items: > + - const: simple-bus > + > + nvmem-cells: > + maxItems: 1 > + description: Phandle to the SOC Unique ID provided by a nvmem node > + > + nvmem-cells-names: > + const: soc_unique_id > + > + allOf: > + - if: > + properties: > + compatible: > + contains: > + enum: > + - fsl,imx8mm-soc > + - fsl,imx8mn-soc > + - fsl,imx8mp-soc > + - fsl,imx8mq-soc > + const: simple-bus > + > + then: > + required: > + - nvmem-cells > + - nvmem-cells-names > > The above is my modification. Is that ok? Does not look like solving anything. Best regards, Krzysztof