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 X-Spam-Level: X-Spam-Status: No, score=-14.7 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5A453C12002 for ; Wed, 14 Jul 2021 19:01:26 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 1A013613BE for ; Wed, 14 Jul 2021 19:01:26 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1A013613BE Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding: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-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=21qVMB1MUDiliMuTEtu0yYjw3qblYyRDXooh0rFneSk=; b=Zu3Qb+IoMtGT2g D/V/IIVI2t6/4dftzEra7d466hOcjriJF+i8UemtDTarPrV3OQaIeu0BjWWjw6wiWMP0/XQqGax/f uZ8Gv2cR3TXxeBFHoug0HlEnIdT43JT7FAfU4ymfujBuB314madArzr20HDKkQ1NOZ7CyASqBiLyA eQKLmJC6L6wd0J9dwb8QiC7pGALzKbW9eDRSz52u/vagmRBM6kFBK2hYujJNH+mLHyvPWmq2LEx7/ m87lZzw2Dc9/sd496TZngU8Po88f7EkKvl5OfKY9S+s/vIqWhz7WKUS0Avftox9DYJa4Q0HFDStDe cC9+uFjPHlWduqf/p41A==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1m3k6V-00ETr0-8f; Wed, 14 Jul 2021 18:59:31 +0000 Received: from mail-io1-f51.google.com ([209.85.166.51]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1m3k6Q-00ETpz-4a for linux-arm-kernel@lists.infradead.org; Wed, 14 Jul 2021 18:59:27 +0000 Received: by mail-io1-f51.google.com with SMTP id l5so3436454iok.7 for ; Wed, 14 Jul 2021 11:59:25 -0700 (PDT) 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:in-reply-to; bh=zqn/UuKDKBVB65aNlLqXAidjfeKUMUwTatpSpLAxY4U=; b=HbILplegWs+DjaImVLf6AZNKdFAFLuuV+/i6mDw8ilmb2ShxhhZnuOMZqSYacnxUY2 J+E7dte/9AL3qcqalrJIiUnB/cEAxRWWEcf58QdlbRlU3SGVHc4PCY/o6P9QH9hHjm3C z9bfDX65bZzwhVYA+lgSAWz33jheopEBy0EpU88CSOf7J/W66jW5+w1QXJG3+/I4bWkT 2/R8YxeoP5FAC2vtWvx8VyjgK+L1uEJRYrTp6P55BxevYpNVFEm2/UpnK8aJtIyjSNZe ZMpF314wVbhC2rd7PCLstppxJRMWlt4fSUKaOgSth5IeeVEOrYTg/KkbzH1nN4lwAlc4 QSbw== X-Gm-Message-State: AOAM530LsztUeo0A6pM1Htj4oqmiUGuXao/oVU5YdVnOxAjbMLFrnTq9 N6f+SGJDMN1Vcuao3KCxrg== X-Google-Smtp-Source: ABdhPJxYKPIleDLKeTmh50SEBn76TTQwAq6xmaa4599i+vpnmfWqT0gXTEERcjvubH19PDmCTkbwVg== X-Received: by 2002:a02:9109:: with SMTP id a9mr10232121jag.93.1626289165340; Wed, 14 Jul 2021 11:59:25 -0700 (PDT) Received: from robh.at.kernel.org ([64.188.179.248]) by smtp.gmail.com with ESMTPSA id r16sm1696281iln.30.2021.07.14.11.59.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Jul 2021 11:59:24 -0700 (PDT) Received: (nullmailer pid 2937232 invoked by uid 1000); Wed, 14 Jul 2021 18:59:22 -0000 Date: Wed, 14 Jul 2021 12:59:22 -0600 From: Rob Herring To: Kunihiko Hayashi Cc: Srinivas Kandagatla , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Masami Hiramatsu , Keiji Hayashibara Subject: Re: [PATCH] dt-bindings: nvmem: Convert UniPhier eFuse bindings to json-schema Message-ID: <20210714185922.GA2857803@robh.at.kernel.org> References: <1624413058-17338-1-git-send-email-hayashi.kunihiko@socionext.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1624413058-17338-1-git-send-email-hayashi.kunihiko@socionext.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210714_115926_232417_C18DCCD2 X-CRM114-Status: GOOD ( 23.43 ) 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: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Wed, Jun 23, 2021 at 10:50:58AM +0900, Kunihiko Hayashi wrote: > Convert the UniPhier eFuse binding to DT schema format. > > Cc: Keiji Hayashibara > Signed-off-by: Kunihiko Hayashi > --- > .../bindings/nvmem/socionext,uniphier-efuse.yaml | 109 +++++++++++++++++++++ > .../devicetree/bindings/nvmem/uniphier-efuse.txt | 49 --------- > 2 files changed, 109 insertions(+), 49 deletions(-) > create mode 100644 Documentation/devicetree/bindings/nvmem/socionext,uniphier-efuse.yaml > delete mode 100644 Documentation/devicetree/bindings/nvmem/uniphier-efuse.txt > > diff --git a/Documentation/devicetree/bindings/nvmem/socionext,uniphier-efuse.yaml b/Documentation/devicetree/bindings/nvmem/socionext,uniphier-efuse.yaml > new file mode 100644 > index 0000000..e03c1ed > --- /dev/null > +++ b/Documentation/devicetree/bindings/nvmem/socionext,uniphier-efuse.yaml > @@ -0,0 +1,109 @@ > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/nvmem/socionext,uniphier-efuse.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Socionext UniPhier eFuse bindings > + > +maintainers: > + - Keiji Hayashibara > + - Kunihiko Hayashi > + > +allOf: > + - $ref: "nvmem.yaml#" > + > +properties: > + "#address-cells": true > + "#size-cells": true > + > + compatible: > + const: socionext,uniphier-efuse > + > + reg: > + maxItems: 1 > + > +patternProperties: > + "^.*@[0-9a-f]+,[0-9]+$": nvmem.yaml has a different definition. Though it doesn't handle overlapping addresses. You should extend nvmem.yaml like you have here. The last part should be optional though. > + type: object > + > + properties: > + reg: > + maxItems: 1 > + > + bits: > + maxItems: 1 > + > + required: > + - reg All this is already defined in nvmem.yaml. > + > +required: > + - compatible > + - reg > + > +additionalProperties: false Use 'unevaluatedProperties: false' and then you don't need to redefine anything common here. > + > +examples: > + - | > + // The UniPhier eFuse should be a subnode of a "soc-glue" node. > + > + soc-glue@5f900000 { > + compatible = "simple-mfd"; > + #address-cells = <1>; > + #size-cells = <1>; > + ranges = <0x0 0x5f900000 0x2000>; > + > + efuse@100 { > + compatible = "socionext,uniphier-efuse"; > + reg = <0x100 0x28>; > + }; > + > + efuse@200 { > + compatible = "socionext,uniphier-efuse"; > + reg = <0x200 0x68>; > + #address-cells = <1>; > + #size-cells = <1>; > + > + /* Data cells */ > + usb_rterm0: trim@54,4 { > + reg = <0x54 1>; > + bits = <4 2>; > + }; > + usb_rterm1: trim@55,4 { > + reg = <0x55 1>; > + bits = <4 2>; > + }; > + usb_rterm2: trim@58,4 { > + reg = <0x58 1>; > + bits = <4 2>; > + }; > + usb_rterm3: trim@59,4 { > + reg = <0x59 1>; > + bits = <4 2>; > + }; > + usb_sel_t0: trim@54,0 { > + reg = <0x54 1>; > + bits = <0 4>; > + }; > + usb_sel_t1: trim@55,0 { > + reg = <0x55 1>; > + bits = <0 4>; > + }; > + usb_sel_t2: trim@58,0 { > + reg = <0x58 1>; > + bits = <0 4>; > + }; > + usb_sel_t3: trim@59,0 { > + reg = <0x59 1>; > + bits = <0 4>; > + }; > + usb_hs_i0: trim@56,0 { > + reg = <0x56 1>; > + bits = <0 4>; > + }; > + usb_hs_i2: trim@5a,0 { > + reg = <0x5a 1>; > + bits = <0 4>; > + }; > + }; > + }; > diff --git a/Documentation/devicetree/bindings/nvmem/uniphier-efuse.txt b/Documentation/devicetree/bindings/nvmem/uniphier-efuse.txt > deleted file mode 100644 > index eccf490..0000000 > --- a/Documentation/devicetree/bindings/nvmem/uniphier-efuse.txt > +++ /dev/null > @@ -1,49 +0,0 @@ > -= UniPhier eFuse device tree bindings = > - > -This UniPhier eFuse must be under soc-glue. > - > -Required properties: > -- compatible: should be "socionext,uniphier-efuse" > -- reg: should contain the register location and length > - > -= Data cells = > -Are child nodes of efuse, bindings of which as described in > -bindings/nvmem/nvmem.txt > - > -Example: > - > - soc-glue@5f900000 { > - compatible = "socionext,uniphier-ld20-soc-glue-debug", > - "simple-mfd"; > - #address-cells = <1>; > - #size-cells = <1>; > - ranges = <0x0 0x5f900000 0x2000>; > - > - efuse@100 { > - compatible = "socionext,uniphier-efuse"; > - reg = <0x100 0x28>; > - }; > - > - efuse@200 { > - compatible = "socionext,uniphier-efuse"; > - reg = <0x200 0x68>; > - #address-cells = <1>; > - #size-cells = <1>; > - > - /* Data cells */ > - usb_mon: usb-mon@54 { > - reg = <0x54 0xc>; > - }; > - }; > - }; > - > -= Data consumers = > -Are device nodes which consume nvmem data cells. > - > -Example: > - > - usb { > - ... > - nvmem-cells = <&usb_mon>; > - nvmem-cell-names = "usb_mon"; > - } > -- > 2.7.4 > > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel