Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp1977454pxb; Sat, 22 Jan 2022 11:59:51 -0800 (PST) X-Google-Smtp-Source: ABdhPJzq/HqMaYcok3rcjGiNWCXVrLtxLm+eD5aJADIoYG+GChCeFJqLQjzUIFfIHNu+F6v77inE X-Received: by 2002:a05:6a00:cd5:b0:4c3:26d5:9bff with SMTP id b21-20020a056a000cd500b004c326d59bffmr8345574pfv.20.1642881591323; Sat, 22 Jan 2022 11:59:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1642881591; cv=none; d=google.com; s=arc-20160816; b=HXsfEghWvEitHMb9EyT/mRYqI8gGCmqP0m6D+cb6e7K8of0WVvZ7mqqbfMUhaNTSDO tuizhRPMl9Y+FRsPpaFxq+pHMCgbATEpKRvHXSZtJYHuUCUJBFXJPKp6Co3pSRSw9tjG k8cXkv7BZzj2M/5de+RoD5lRh3cP8/odFaZFqP7aPGzGkKtJLBEdKhfKz370ezjqZsW/ yQJiXNK9gNicNypqJxYPy3K8Q/6r05MMuLQgZM3yT8Lj/XwE+CCSRQgAnfAKVmNWPlmF O9phbF5fGtltViZ8NaweXPShETeAqzW82LUF0Ei0YyXVc5H18DHrxX7Gya3r3Y+nRlN9 LuIg== 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-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=L8s5mBf0UpHtEY/qnha+jJ91j6Jh+IbHCl/z4sZacfE=; b=zkfG6YDzqNQfcASNTaLlVniUAuu+cCuS6LROszskuHpSriKtDXY7aLkkLwMjqhb23R QCV7SyQZ7FCejFkAgU+EzgQfA8ah3NpIktMQ+mU8PXb0ZQO3JLdhGgpMyPPOrG7bMuWM Ct+a31ABqu/BdnlUKaMsmz1Ff5NdnSC0Y17AhTfQCOlQaOfVVSWQHmkABMFC1qIq4477 gIRignuqOleUchJnyLp7vecOSQmakQRneUX/mTDDJlw+VBV8q9033fPiA55djt9CSbI6 DJ6CssT/VbjyY7cEG82HYAhAmtmSQpSz7P2mQvMBcq6WyAoBQkTf2T3bczrV89i3H/2Q nKwQ== 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 c9si9745615plg.216.2022.01.22.11.59.39; Sat, 22 Jan 2022 11:59:51 -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 S231403AbiAVA5L (ORCPT + 99 others); Fri, 21 Jan 2022 19:57:11 -0500 Received: from mail-oo1-f41.google.com ([209.85.161.41]:35655 "EHLO mail-oo1-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231215AbiAVA5D (ORCPT ); Fri, 21 Jan 2022 19:57:03 -0500 Received: by mail-oo1-f41.google.com with SMTP id p4-20020a4a8e84000000b002e598a51d60so508022ook.2; Fri, 21 Jan 2022 16:57:03 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=L8s5mBf0UpHtEY/qnha+jJ91j6Jh+IbHCl/z4sZacfE=; b=hcTBlz6j2XwvR23/hdn8m3atHq4bb5X1fwJJR+fJ0g/YNqjBUonhhCAoEcqMOi10hR DvkKocF/Drw+ZUl8hx5Qty3n3Cm/irYU1j0yLXFuynW5c3oNhSsMUblWpUrEHnQxrvH3 0sKk9ivyF5elryU57+f5C5G40L6cG8jl/e1dvA6EELu3obZStKBtl8NmY3/RZdKTBBay 2POJ9Z/TWRiwRd1sYduxhVVr9DzAI3dLu7PFEUJwKXpLfMRAjBoAF0iXX4nw4bVvGp7J m0yY3yhOH823dloISYdG1UpkiyPYdi+vP7UzmxXcaq9uQlv4bHIN6SgMY2MD2Z2TwOSP MBnQ== X-Gm-Message-State: AOAM5301n9Q1iuj0cKEM3rIrWPbeBooDNqh/ya+GbHJYCHE3B+JZk+0h HXTvjl4AxK1vFrsUIEV+3A== X-Received: by 2002:a4a:c57:: with SMTP id n23mr4154768ooe.55.1642813023151; Fri, 21 Jan 2022 16:57:03 -0800 (PST) Received: from robh.at.kernel.org (66-90-148-213.dyn.grandenetworks.net. [66.90.148.213]) by smtp.gmail.com with ESMTPSA id q25sm1916041oiw.27.2022.01.21.16.57.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 21 Jan 2022 16:57:02 -0800 (PST) Received: (nullmailer pid 1955852 invoked by uid 1000); Sat, 22 Jan 2022 00:57:01 -0000 Date: Fri, 21 Jan 2022 18:57:01 -0600 From: Rob Herring To: Leilk Liu Cc: Mark Brown , Matthias Brugger , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-spi@vger.kernel.org, linux-mediatek@lists.infradead.org Subject: Re: [PATCH V2 2/3] dt-bindings: spi: Convert spi-mt65xx to json-schema Message-ID: References: <20220112103609.17421-1-leilk.liu@mediatek.com> <20220112103609.17421-3-leilk.liu@mediatek.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220112103609.17421-3-leilk.liu@mediatek.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jan 12, 2022 at 06:36:08PM +0800, Leilk Liu wrote: > Convert Mediatek ARM SOC's SPI Master controller binding > to json-schema format. > > Signed-off-by: Leilk Liu > --- > .../bindings/spi/mediatek,spi-mt65xx.yaml | 99 +++++++++++++++++++ > .../devicetree/bindings/spi/spi-mt65xx.txt | 68 ------------- > 2 files changed, 99 insertions(+), 68 deletions(-) > create mode 100644 Documentation/devicetree/bindings/spi/mediatek,spi-mt65xx.yaml > delete mode 100644 Documentation/devicetree/bindings/spi/spi-mt65xx.txt > > diff --git a/Documentation/devicetree/bindings/spi/mediatek,spi-mt65xx.yaml b/Documentation/devicetree/bindings/spi/mediatek,spi-mt65xx.yaml > new file mode 100644 > index 000000000000..71f0cf6e5d70 > --- /dev/null > +++ b/Documentation/devicetree/bindings/spi/mediatek,spi-mt65xx.yaml > @@ -0,0 +1,99 @@ > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/spi/mediatek,spi-mt65xx.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: SPI Bus controller for MediaTek ARM SoCs > + > +maintainers: > + - Leilk Liu > + > +allOf: > + - $ref: /spi/spi-controller.yaml# /schemas/spi/spi-controller.yaml# > + > +properties: > + compatible: > + oneOf: > + - items: > + - enum: > + - mediatek,mt7629-spi > + - const: mediatek,mt7622-spi > + - items: > + - enum: > + - mediatek,mt8516-spi > + - const: mediatek,mt2712-spi > + - items: > + - enum: > + - mediatek,mt6779-spi > + - mediatek,mt8192-spi > + - mediatek,mt8195-spi > + - const: mediatek,mt6765-spi > + - const: mediatek,mt2701-spi > + - const: mediatek,mt2712-spi > + - const: mediatek,mt6589-spi > + - const: mediatek,mt6765-spi > + - const: mediatek,mt6893-spi > + - const: mediatek,mt7622-spi > + - const: mediatek,mt8135-spi > + - const: mediatek,mt8173-spi > + - const: mediatek,mt8183-spi All these can be 1 enum. > + > + reg: > + maxItems: 1 > + > + interrupts: > + maxItems: 1 > + > + clocks: > + items: > + - description: clock used for the parent clock > + - description: clock used for the muxes clock > + - description: clock used for the clock gate > + > + clock-names: > + items: > + - const: parent-clk > + - const: sel-clk > + - const: spi-clk > + > + mediatek,pad-select: > + $ref: /schemas/types.yaml#/definitions/uint32-array > + maxItems: 4 > + items: > + enum: [0, 1, 2, 3] > + description: > + specify which pins group(ck/mi/mo/cs) spi controller used. > + This is an array. > + > +required: > + - compatible > + - reg > + - interrupts > + - clocks > + - clock-names > + - '#address-cells' > + - '#size-cells' > + > +unevaluatedProperties: false > + > +examples: > + - | > + #include > + #include > + #include > + #include > + > + spi@1100a000 { > + compatible = "mediatek,mt8173-spi"; > + #address-cells = <1>; > + #size-cells = <0>; > + reg = <0x1100a000 0x1000>; > + interrupts = ; > + clocks = <&topckgen CLK_TOP_SYSPLL3_D2>, > + <&topckgen CLK_TOP_SPI_SEL>, > + <&pericfg CLK_PERI_SPI0>; > + clock-names = "parent-clk", "sel-clk", "spi-clk"; > + cs-gpios = <&pio 105 GPIO_ACTIVE_LOW>, <&pio 72 GPIO_ACTIVE_LOW>; > + mediatek,pad-select = <1>, <0>; > + };