From patchwork Sat Sep 5 17:30:03 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 249171 Delivered-To: patch@linaro.org Received: by 2002:a92:5b9c:0:0:0:0:0 with SMTP id c28csp2420853ilg; Sat, 5 Sep 2020 10:33:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz88FXTFPRZvyHkgcIPvRw2PRyhETzhIPKN74gwy+KruhluUJE6KqTdNsbNgb7EHrDTdFd0 X-Received: by 2002:a17:907:40c1:: with SMTP id nv1mr6613044ejb.318.1599327182555; Sat, 05 Sep 2020 10:33:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599327182; cv=none; d=google.com; s=arc-20160816; b=rlHN1sVdvFsIcQAbcWjLb4tMhadrr2fN+hsS8ZCoSnBMnMJ0S3OvlemNgZcwmw9Gm/ aud5GjGrximkgKilSB372yNmMGLPZxl4t+42rXzqMwnJ2peltuLbwZhmHLTtuvrGwtjA 9QgplNR17+BezHibHMTd2JO2Xe7mTJ8nRPF7evHz9wLKiD+3F2ERsChHljA+tSlT0v7a yBFRKLFuCaj3ua3FGcaYJo5w4B3Gjvyh2ObZ+T9NfT1/GnOdwEZAglok8Khl5vPcwBRx ewr1OBZGuhA4XFWuWALWcA2Ke0jD4ln32+GpAbQJXsW8HvRzNEZ8AcO9ENLL29FFh7e3 jg1g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=RWZ764Dc0jbdRDKRwQPHlJDvXLQ/R4u6JXCXJv68JOQ=; b=J5Um8AG7q6nlQCbUu0ko+tNR1fufDcYps8Zy1IHCjOnCuoce0JZ/6LOs60KAsZK0Zb auozC6L6thyu4oTl3655AGltcOUu7lPo9eecEhvc9IR9quorStE1NEfnt2igZSPjzenP msV3jBE/+9+GCt2+zN8/siKWKVmrg6p3jg9XvOXyYKlzExOyIymY8TGrr42Btm5Zpew5 zy/g8kt0aBe2t2bxcNs1LxsxOtsBOtwK4Aph0wmxppgmOWdZh6baV23Bk0kaJX9JZRYB JaWIy8O84gaUk9RCR9zeQa/Tkv2tFYvREBdQjMDz5hvUoYq9270xNPEREfXg0lBVA7zm ekDQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=PNA0Omff; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-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 u17si5687486ejk.29.2020.09.05.10.33.01; Sat, 05 Sep 2020 10:33:02 -0700 (PDT) Received-SPF: pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=PNA0Omff; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-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 S1728572AbgIERc6 (ORCPT + 6 others); Sat, 5 Sep 2020 13:32:58 -0400 Received: from mail.kernel.org ([198.145.29.99]:60562 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728555AbgIERcz (ORCPT ); Sat, 5 Sep 2020 13:32:55 -0400 Received: from localhost.localdomain (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2E1FA2078E; Sat, 5 Sep 2020 17:32:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1599327174; bh=/O5xMlBLoa1fQ2/9iy12YsyhTYvUp2gU+bzHqJg7V8o=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=PNA0OmffL8B+EFA74jkL30PsnbFjizr0IdOPyVRrWgFIJqe3d8gJGv/IdeIQlS+E+ R5yZAmSzfnlwNtbHGefyWfjbX8+kDE/7j3Yugw1BTnOxr/UbYdDVwpyqtbtiaw+h+q s1e3r1j58itqnah7URwHH1QhA+HIxdShlyHEG3Ng= From: Jonathan Cameron To: linux-iio@vger.kernel.org, Rob Herring , devicetree@vger.kernel.org Cc: Jonathan Cameron , Haibo Chen , Shawn Guo , Sascha Hauer Subject: [PATCH 19/20] dt-bindings:iio:adc:fsl,imx7d-adc yaml conversion Date: Sat, 5 Sep 2020 18:30:03 +0100 Message-Id: <20200905173004.216081-20-jic23@kernel.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200905173004.216081-1-jic23@kernel.org> References: <20200905173004.216081-1-jic23@kernel.org> MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Jonathan Cameron A nice simple binding. Only real different from txt is that I dropped some descriptions where the naming of the parameter was self explanatory Signed-off-by: Jonathan Cameron Cc: Haibo Chen Cc: Shawn Guo Cc: Sascha Hauer --- .../bindings/iio/adc/fsl,imx7d-adc.yaml | 62 +++++++++++++++++++ .../devicetree/bindings/iio/adc/imx7d-adc.txt | 24 ------- 2 files changed, 62 insertions(+), 24 deletions(-) -- 2.28.0 diff --git a/Documentation/devicetree/bindings/iio/adc/fsl,imx7d-adc.yaml b/Documentation/devicetree/bindings/iio/adc/fsl,imx7d-adc.yaml new file mode 100644 index 000000000000..dc5eacb38046 --- /dev/null +++ b/Documentation/devicetree/bindings/iio/adc/fsl,imx7d-adc.yaml @@ -0,0 +1,62 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/iio/adc/fsl,imx7d-adc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Freescale ADC found on the imx7d SoC + +maintainers: + - Haibo Chen + +properties: + compatible: + const: fsl,imx7d-adc + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + clocks: + maxItems: 1 + + clock-names: + const: adc + + vref-supply: true + + "#io-channel-cells": + const: 1 + +required: + - compatible + - reg + - interrupts + - clocks + - clock-names + - vref-supply + - "#io-channel-cells" + +additionalProperties: false + +examples: + - | + #include + #include + #include + soc { + #address-cells = <1>; + #size-cells = <1>; + adc@30610000 { + compatible = "fsl,imx7d-adc"; + reg = <0x30610000 0x10000>; + interrupts = ; + clocks = <&clks IMX7D_ADC_ROOT_CLK>; + clock-names = "adc"; + vref-supply = <®_vcc_3v3_mcu>; + #io-channel-cells = <1>; + }; + }; +... diff --git a/Documentation/devicetree/bindings/iio/adc/imx7d-adc.txt b/Documentation/devicetree/bindings/iio/adc/imx7d-adc.txt deleted file mode 100644 index f1f3a552459b..000000000000 --- a/Documentation/devicetree/bindings/iio/adc/imx7d-adc.txt +++ /dev/null @@ -1,24 +0,0 @@ -Freescale imx7d ADC bindings - -The devicetree bindings are for the ADC driver written for -imx7d SoC. - -Required properties: -- compatible: Should be "fsl,imx7d-adc" -- reg: Offset and length of the register set for the ADC device -- interrupts: The interrupt number for the ADC device -- clocks: The root clock of the ADC controller -- clock-names: Must contain "adc", matching entry in the clocks property -- vref-supply: The regulator supply ADC reference voltage -- #io-channel-cells: Must be 1 as per ../iio-bindings.txt - -Example: -adc1: adc@30610000 { - compatible = "fsl,imx7d-adc"; - reg = <0x30610000 0x10000>; - interrupts = ; - clocks = <&clks IMX7D_ADC_ROOT_CLK>; - clock-names = "adc"; - vref-supply = <®_vcc_3v3_mcu>; - #io-channel-cells = <1>; -};