From patchwork Fri Nov 18 14:33:36 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 22363 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp231001wrr; Fri, 18 Nov 2022 06:38:27 -0800 (PST) X-Google-Smtp-Source: AA0mqf77E9pNWY8vdzr2z7oshG7vcWSycm8N7H1VHHsQrwMFsh6xiXqhgkMXutQVmyzglt82RucC X-Received: by 2002:a17:906:d1c7:b0:7ad:fd3e:7762 with SMTP id bs7-20020a170906d1c700b007adfd3e7762mr6218479ejb.717.1668782307213; Fri, 18 Nov 2022 06:38:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668782307; cv=none; d=google.com; s=arc-20160816; b=Y4Z00tys6DuT0dE8bJR++34YfF6n81YCH5JrlvL80BLp4Ez9JZHYOb190A5ly5UYTi 6x1470Qn0HyTdavfDBA36K8T4WqfOeawP1TWcsTHGUYDJ/sRJ4EKW9g2cV9mXZZaM0QG o4pWfxXj9TKZQ1NBQHNGoUTQtWrfw4AR4QPHdZPxPmqSgmzEJnA850Ht4Pcs+U1GGvQO YrrWSnLKCkwzm2ND7UV8Hnqrz5N41tr44c/wLGkbji3eUh2UGoxtalQ8G5h/0QoZLgN/ yjRgWN81QMuNsl34BYalyt2qQ7EmwmYSp70edUEsNuVqC3u5ztMauw3m+bJ1CAJhe6Bn 6+XA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=xLXGft1LTrsRUm/stssOzl0Wu0Tv4L36SFUjpXRih0U=; b=GO6VGSoH6vbsh5Hb2YNyQOfpk1RGk34nx4JuX8SZ+KiIWiXdV+fWhqmx+9dwSDXLqH Qd3BpYl8DAw2p4zsKBIJQcVdKy9Jtu1hoteczaRqi78Rz8ellQ5Pih9hiqW/VpnNj4bO hA8BauaEqhjKdtUykrZhgZlA2vjRH27T7gPOk6FEW90GVdGz+p/J4jgph7MaZ2BKaUTY Ny/rOPAPZwZSr1D7hs/V5Jr+B/JV6ctIxoTXQEe3gjauZeULIhiSm+8/TUu6KVNM/jSE F6SoIMS763K3chrGR+ljXCJffaBM4V+Divvwt3FeWCRtKHKQf9N1McIsTuIh3oRz7RGg u63w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cCR5gQy5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id cy2-20020a0564021c8200b00462750bbe08si3023886edb.522.2022.11.18.06.38.02; Fri, 18 Nov 2022 06:38:27 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cCR5gQy5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235218AbiKROfo (ORCPT + 99 others); Fri, 18 Nov 2022 09:35:44 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36180 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242082AbiKROeu (ORCPT ); Fri, 18 Nov 2022 09:34:50 -0500 Received: from mail-wr1-x436.google.com (mail-wr1-x436.google.com [IPv6:2a00:1450:4864:20::436]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 415BB8FE58 for ; Fri, 18 Nov 2022 06:33:47 -0800 (PST) Received: by mail-wr1-x436.google.com with SMTP id d9so9493209wrm.13 for ; Fri, 18 Nov 2022 06:33:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=xLXGft1LTrsRUm/stssOzl0Wu0Tv4L36SFUjpXRih0U=; b=cCR5gQy562wvY7HQ1tfOAsEkzRhd5Q67vmDhpKmXdhgwcXETjvsGX1J4mU9pCcNhV4 c+Mc00TU+/VeylHvYs5E0MnIxYMkiSJ5qbqI+34tyGUSNO9RGoGb93KXrFmg4kBwz4sl 4thkPqltfrVF30zr5uUyfhZ7eAOr0grm4V84lVwTr2NqhKpjXEDdkOYMVqxrlfV6LeWY RJ1wBOHq7O34tVSUCtLq/MQUgq/jAyVT9beK7sU6Uu43xH623nWYhGBDiDoYqdx/L9Nh HoH408Wcb8xfa9OozfxyU92ujUElSLyXDP8Wg+ouxedfxijEjU3QB62Dt5KIYW7GDdkI EwOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xLXGft1LTrsRUm/stssOzl0Wu0Tv4L36SFUjpXRih0U=; b=doZr4dgxFA/ss4HQLXAWnBNB+32cVW0hYo0BD+mKRzT60rGyARUS4kjW2iwqD36aiJ l9P4o3++5N3hPLZ9nKyes5mgj9ne2gNLiVGrBu+mQGTl0I/HpD/wSqdxloAbhyoDHq1V 8KIcC3XPuzoTyLX0zcId6Ppzr2rtq5UjfF1OmXkFDPrNu3MpVDXYOtwDY2tV9iUsmbhQ gm2LDdKijUEC7p0bTM7EZF+lTJyXLXkFV8eOf1ceE6LZtVLSjFxPwn/PJU2sBGfaq/pl MlBS1DsoZ7TbVYhKFgPiEUSXecN4J/xMRxgFcu4e0wkEo6LoiZnII0AucSDLxVUwuuRo lBxw== X-Gm-Message-State: ANoB5pkBnKtpD1H+z1sDfvFuKt6A3mIl/RQ8QapnZs2BQBBck1dnhXy/ WT+N8r2PopXERa5umrvL/4tbnQ== X-Received: by 2002:adf:b342:0:b0:236:62ce:3db with SMTP id k2-20020adfb342000000b0023662ce03dbmr4460768wrd.687.1668782025463; Fri, 18 Nov 2022 06:33:45 -0800 (PST) Received: from arrakeen.starnux.net ([2a01:e0a:982:cbb0:52eb:f6ff:feb3:451a]) by smtp.gmail.com with ESMTPSA id j21-20020a05600c1c1500b003cfb7c02542sm5436726wms.11.2022.11.18.06.33.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 18 Nov 2022 06:33:45 -0800 (PST) From: Neil Armstrong Date: Fri, 18 Nov 2022 15:33:36 +0100 Subject: [PATCH 10/12] dt-bindings: mmc: convert amlogic,meson-gx.txt to dt-schema MIME-Version: 1.0 Message-Id: <20221117-b4-amlogic-bindings-convert-v1-10-3f025599b968@linaro.org> References: <20221117-b4-amlogic-bindings-convert-v1-0-3f025599b968@linaro.org> In-Reply-To: <20221117-b4-amlogic-bindings-convert-v1-0-3f025599b968@linaro.org> To: Jakub Kicinski , Wim Van Sebroeck , Srinivas Kandagatla , Rob Herring , Andrew Lunn , Alessandro Zummo , Eric Dumazet , Bjorn Helgaas , Kevin Hilman , Ulf Hansson , Heiner Kallweit , Vinod Koul , Russell King , Thomas Gleixner , Kishon Vijay Abraham I , Guenter Roeck , Krzysztof Kozlowski , Martin Blumenstingl , Alexandre Belloni , Daniel Lezcano , Jerome Brunet , Paolo Abeni , Mauro Carvalho Chehab , "David S. Miller" Cc: linux-media@vger.kernel.org, netdev@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-mmc@vger.kernel.org, linux-rtc@vger.kernel.org, linux-phy@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-watchdog@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, Neil Armstrong , devicetree@vger.kernel.org X-Mailer: b4 0.10.1 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1749845076440828622?= X-GMAIL-MSGID: =?utf-8?q?1749845076440828622?= Convert the Amlogic SD / eMMC controller for S905/GXBB family SoCs to dt-schema. Signed-off-by: Neil Armstrong --- .../bindings/mmc/amlogic,meson-gx-mmc.yaml | 78 ++++++++++++++++++++++ .../devicetree/bindings/mmc/amlogic,meson-gx.txt | 39 ----------- 2 files changed, 78 insertions(+), 39 deletions(-) diff --git a/Documentation/devicetree/bindings/mmc/amlogic,meson-gx-mmc.yaml b/Documentation/devicetree/bindings/mmc/amlogic,meson-gx-mmc.yaml new file mode 100644 index 000000000000..c9545334fd99 --- /dev/null +++ b/Documentation/devicetree/bindings/mmc/amlogic,meson-gx-mmc.yaml @@ -0,0 +1,78 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/mmc/amlogic,meson-gx-mmc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Amlogic SD / eMMC controller for S905/GXBB family SoCs + +description: + The MMC 5.1 compliant host controller on Amlogic provides the + interface for SD, eMMC and SDIO devices + +maintainers: + - Neil Armstrong + +allOf: + - $ref: mmc-controller.yaml# + +properties: + compatible: + oneOf: + - enum: + - amlogic,meson-gx-mmc + - amlogic,meson-axg-mmc + - items: + - enum: + - amlogic,meson-gxbb-mmc + - amlogic,meson-gxl-mmc + - amlogic,meson-gxm-mmc + - const: amlogic,meson-gx-mmc + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + clocks: + maxItems: 3 + + clock-names: + items: + - const: core + - const: clkin0 + - const: clkin1 + + resets: + maxItems: 1 + + amlogic,dram-access-quirk: + type: boolean + description: + set when controller's internal DMA engine cannot access the DRAM memory, + like on the G12A dedicated SDIO controller. + +required: + - compatible + - reg + - interrupts + - clocks + - clock-names + - resets + +unevaluatedProperties: false + +examples: + - | + #include + #include + mmc@70000 { + compatible = "amlogic,meson-gx-mmc"; + reg = <0x70000 0x2000>; + interrupts = ; + clocks = <&clk_mmc>, <&xtal>, <&clk_div>; + clock-names = "core", "clkin0", "clkin1"; + pinctrl-0 = <&emm_pins>; + resets = <&reset_mmc>; + }; diff --git a/Documentation/devicetree/bindings/mmc/amlogic,meson-gx.txt b/Documentation/devicetree/bindings/mmc/amlogic,meson-gx.txt deleted file mode 100644 index ccc5358db131..000000000000 --- a/Documentation/devicetree/bindings/mmc/amlogic,meson-gx.txt +++ /dev/null @@ -1,39 +0,0 @@ -Amlogic SD / eMMC controller for S905/GXBB family SoCs - -The MMC 5.1 compliant host controller on Amlogic provides the -interface for SD, eMMC and SDIO devices. - -This file documents the properties in addition to those available in -the MMC core bindings, documented by mmc.txt. - -Required properties: -- compatible : contains one of: - - "amlogic,meson-gx-mmc" - - "amlogic,meson-gxbb-mmc" - - "amlogic,meson-gxl-mmc" - - "amlogic,meson-gxm-mmc" - - "amlogic,meson-axg-mmc" -- clocks : A list of phandle + clock-specifier pairs for the clocks listed in clock-names. -- clock-names: Should contain the following: - "core" - Main peripheral bus clock - "clkin0" - Parent clock of internal mux - "clkin1" - Other parent clock of internal mux - The driver has an internal mux clock which switches between clkin0 and clkin1 depending on the - clock rate requested by the MMC core. -- resets : phandle of the internal reset line - -Optional properties: -- amlogic,dram-access-quirk: set when controller's internal DMA engine cannot access the - DRAM memory, like on the G12A dedicated SDIO controller. - -Example: - - sd_emmc_a: mmc@70000 { - compatible = "amlogic,meson-gxbb-mmc"; - reg = <0x0 0x70000 0x0 0x2000>; - interrupts = < GIC_SPI 216 IRQ_TYPE_EDGE_RISING>; - clocks = <&clkc CLKID_SD_EMMC_A>, <&xtal>, <&clkc CLKID_FCLK_DIV2>; - clock-names = "core", "clkin0", "clkin1"; - pinctrl-0 = <&emmc_pins>; - resets = <&reset RESET_SD_EMMC_A>; - };