From patchwork Fri Aug 30 14:51:20 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dharma Balasubiramani X-Patchwork-Id: 13785218 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 C36CACA0FFD for ; Fri, 30 Aug 2024 14:54:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:CC:To:In-Reply-To:References :Message-ID:Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date: From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=Avq6wqIHi6pnSQ85pq5cm/jVo35P936Guu3huhjdTqs=; b=maTs8sWA5HHYvf7b9jwaFBnfA2 V2GYVsh5+sVtS2rc3YKbFPDGnGPdJ/miwBK1pCYo/vf9r9MPivCzZxh4733ja+z8I9IMo8PjDDUsE EWMkrRhY6JfTFCqwZTa9yfmX2qwON6T5RMU72HnKmfUR3XGD0j+q1jGLUoJrDZ3h1/PIrQ0IEsY/3 2l/vKIZ77jSgZ2sDegaEQfwOAoutEPqedi/0+aASNkMYYGt3KCpiw4Uxk5ngDFuElkRsgBGA6sjuc PdK2Gxqd8C0jDKi/1p8HJNRFxepPohH9jGxJVonsjTZZF0totH9gOM5y/aeh8bEbo8s9PQb/Hkb2D lvdXMX0g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sk31C-00000006gSM-24gj; Fri, 30 Aug 2024 14:54:30 +0000 Received: from esa.microchip.iphmx.com ([68.232.153.233]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sk2zI-00000006fxZ-0a4r for linux-arm-kernel@lists.infradead.org; Fri, 30 Aug 2024 14:52:33 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1725029552; x=1756565552; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=CNEIm5PnFZJmWeAl6BE1N6y7V3hbmu1mNPTzEXRqxK4=; b=izmgrZVerb9BjBeob57DcwpmTLqYLiVmIetQCb01vo2X3VB6gS1OFIwl fAEEDbZ9C/2NWuzYvFmkNSkOexjDuzQIYUsGvzzfPphySgstc+2ez5IqT fYpIGEonhW8a+J5P3PUG0DYsMxZggavjf33Bd5PwWkv+SyRVFioWtLgAq 4AfsHVkai4G6iPIy+5P+7XbNGnOH2mti/XH425WSv/bDoqysuNV+3SOED 9lzkTmQM6OjNgPJglu+NKOvbm6pOi/1AkLY5szqI8e/++qp0tEEZQpI7j 8S6mEcQOJZ3h69Bpwz+Tq/xUMjamK7Q2JyiK/JHA6VrxKTQk50/POpir7 g==; X-CSE-ConnectionGUID: 2zZRB9uxQuqDg306Gmx2hg== X-CSE-MsgGUID: 7/WDRQ9yQseza/p2GshC6A== X-IronPort-AV: E=Sophos;i="6.10,189,1719903600"; d="scan'208";a="31104532" X-Amp-Result: SKIPPED(no attachment in message) Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa3.microchip.iphmx.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 30 Aug 2024 07:52:30 -0700 Received: from chn-vm-ex03.mchp-main.com (10.10.85.151) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Fri, 30 Aug 2024 07:51:48 -0700 Received: from che-lt-i70843lx.mchp-main.com (10.10.85.11) by chn-vm-ex03.mchp-main.com (10.10.85.151) with Microsoft SMTP Server id 15.1.2507.35 via Frontend Transport; Fri, 30 Aug 2024 07:51:41 -0700 From: Dharma Balasubiramani Date: Fri, 30 Aug 2024 20:21:20 +0530 Subject: [PATCH v3 1/2] dt-bindings: mmc: sdhci-atmel: Convert to json schema MIME-Version: 1.0 Message-ID: <20240830-atmel-sdhci-v3-1-7c97a0872af4@microchip.com> References: <20240830-atmel-sdhci-v3-0-7c97a0872af4@microchip.com> In-Reply-To: <20240830-atmel-sdhci-v3-0-7c97a0872af4@microchip.com> To: Ulf Hansson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Nicolas Ferre , Alexandre Belloni , Claudiu Beznea , Aubin Constans CC: , , , , Dharma Balasubiramani X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1725029490; l=4662; i=dharma.b@microchip.com; s=20240209; h=from:subject:message-id; bh=CNEIm5PnFZJmWeAl6BE1N6y7V3hbmu1mNPTzEXRqxK4=; b=lcJCTUuGXUl2Zwbw0BhytjcMlrl0Es0XxoWWB792wbISSkojPKgjHqrNE9Wbhj0+yWmXjHPi5 x3PlJoU9NpHDMMLlhVznRTgNXTrb9M90BDFKn7x/bafZkpTVMCwTshZ X-Developer-Key: i=dharma.b@microchip.com; a=ed25519; pk=kCq31LcpLAe9HDfIz9ZJ1U7T+osjOi7OZSbe0gqtyQ4= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240830_075232_231565_1856E196 X-CRM114-Status: GOOD ( 17.28 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Convert sdhci-atmel documentation to yaml format. The new file will inherit from sdhci-common.yaml. Note: Add microchip,sama7g5-sdhci to compatible list as we already use it in the DT. Signed-off-by: Dharma Balasubiramani --- .../bindings/mmc/atmel,sama5d2-sdhci.yaml | 90 ++++++++++++++++++++++ .../devicetree/bindings/mmc/sdhci-atmel.txt | 35 --------- 2 files changed, 90 insertions(+), 35 deletions(-) diff --git a/Documentation/devicetree/bindings/mmc/atmel,sama5d2-sdhci.yaml b/Documentation/devicetree/bindings/mmc/atmel,sama5d2-sdhci.yaml new file mode 100644 index 000000000000..ba4786328833 --- /dev/null +++ b/Documentation/devicetree/bindings/mmc/atmel,sama5d2-sdhci.yaml @@ -0,0 +1,90 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/mmc/atmel,sama5d2-sdhci.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Atmel SDHCI controller + +maintainers: + - Aubin Constans + - Nicolas Ferre + +description: + Bindings for the SDHCI controller found in Atmel/Microchip SoCs. + +properties: + compatible: + oneOf: + - enum: + - atmel,sama5d2-sdhci + - atmel,sama5d3-sdhci + - atmel,sama5d4-sdhci + - microchip,sam9x60-sdhci + - items: + - enum: + - microchip,sama7g5-sdhci + - const: microchip,sam9x60-sdhci + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + clocks: + items: + - description: hclock + - description: multclk + - description: baseclk + minItems: 2 + + clock-names: + items: + - const: hclock + - const: multclk + - const: baseclk + minItems: 2 + + microchip,sdcal-inverted: + type: boolean + description: + When present, polarity on the SDCAL SoC pin is inverted. + +required: + - compatible + - reg + - interrupts + - clocks + - clock-names + +allOf: + - $ref: sdhci-common.yaml# + - if: + properties: + compatible: + contains: + enum: + - atmel,sama5d2-sdhci + then: + properties: + clocks: + minItems: 3 + clock-names: + minItems: 3 + +unevaluatedProperties: false + +examples: + - | + #include + #include + mmc@a0000000 { + compatible = "atmel,sama5d2-sdhci"; + reg = <0xa0000000 0x300>; + interrupts = <31 IRQ_TYPE_LEVEL_HIGH 0>; + clocks = <&sdmmc0_hclk>, <&sdmmc0_gclk>, <&main>; + clock-names = "hclock", "multclk", "baseclk"; + assigned-clocks = <&sdmmc0_gclk>; + assigned-clock-rates = <480000000>; + }; diff --git a/Documentation/devicetree/bindings/mmc/sdhci-atmel.txt b/Documentation/devicetree/bindings/mmc/sdhci-atmel.txt deleted file mode 100644 index a9fb0a91245f..000000000000 --- a/Documentation/devicetree/bindings/mmc/sdhci-atmel.txt +++ /dev/null @@ -1,35 +0,0 @@ -* Atmel SDHCI controller - -This file documents the differences between the core properties in -Documentation/devicetree/bindings/mmc/mmc.txt and the properties used by the -sdhci-of-at91 driver. - -Required properties: -- compatible: Must be "atmel,sama5d2-sdhci" or "microchip,sam9x60-sdhci" - or "microchip,sam9x7-sdhci", "microchip,sam9x60-sdhci". -- clocks: Phandlers to the clocks. -- clock-names: Must be "hclock", "multclk", "baseclk" for - "atmel,sama5d2-sdhci". - Must be "hclock", "multclk" for "microchip,sam9x60-sdhci". - Must be "hclock", "multclk" for "microchip,sam9x7-sdhci". - -Optional properties: -- assigned-clocks: The same with "multclk". -- assigned-clock-rates The rate of "multclk" in order to not rely on the - gck configuration set by previous components. -- microchip,sdcal-inverted: when present, polarity on the SDCAL SoC pin is - inverted. The default polarity for this signal is described in the datasheet. - For instance on SAMA5D2, the pin is usually tied to the GND with a resistor - and a capacitor (see "SDMMC I/O Calibration" chapter). - -Example: - -mmc0: sdio-host@a0000000 { - compatible = "atmel,sama5d2-sdhci"; - reg = <0xa0000000 0x300>; - interrupts = <31 IRQ_TYPE_LEVEL_HIGH 0>; - clocks = <&sdmmc0_hclk>, <&sdmmc0_gclk>, <&main>; - clock-names = "hclock", "multclk", "baseclk"; - assigned-clocks = <&sdmmc0_gclk>; - assigned-clock-rates = <480000000>; -};