From patchwork Sat Sep 5 17:29:57 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 249176 Delivered-To: patch@linaro.org Received: by 2002:a92:5b9c:0:0:0:0:0 with SMTP id c28csp2420941ilg; Sat, 5 Sep 2020 10:33:10 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwvdLLWGQrT3NJeyCdgUdkf3tSFIgezgQpJiImxe+ZCRvVZ+B1OuABM3ODPSXDfFMvioe3F X-Received: by 2002:a17:906:77d1:: with SMTP id m17mr13565149ejn.96.1599327190267; Sat, 05 Sep 2020 10:33:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599327190; cv=none; d=google.com; s=arc-20160816; b=tHzxkmjs2BZV+jKcWteJ+ETEurFRIwMN0ulUKbtdeAE8mBxwwildx1g6hLsYkvw3eL ZDyGOM2On0VGqGcJlHJdReipG68W1CeG6wxU6YkrEu3WA2eOVBV32UdxryT2SJXdaht7 CdEAokmWH5Qfmwf6EactIPJkS1dxCNUQ2fzV8n9/1cb69dyNgt9xvsGO0ktOWL86OIjk mjEevSAMmHeod4kI804d0hV8pZBov9vrC8gedKwzb1/kMj0BEg4pSJaUffmNH0sClHi4 sp+LDMFl974Uk9s1VrNL8M7Ny+zkIR11q/OlC4RoZ02p5XOpJbCJkb5IdtyHI09Y0kTn gpIw== 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=9SydJVmd1GvANJIthVbPoprvB5ALe8nqljVhwr6t3BM=; b=qlxZWC/m9D7+OAqpBV8Bengz52fEx6lJljRyl8gpKFQxc/SMuWAaVFnviTte0c1T8S s3kf1rdMx/LfinvdG2n0/FCcGxGD/1vqxOAvlur/YcLXIW4Y+36nPm8YvwNha4nIFo9f B85jn8AG5X0KSa7U/eNZ2L8KcpxzMOEzKecWLXIuXQ45f8MGpjvUYs9R131z988ls2O8 4k5qyCYLaxl6nxGlU2NmJFYvbLQHpVwUl50jrzG3AC3Kr3iSYiOdw1IM/S5vrb0D0m5S 6AyH5FkNxFy8Sc4WSkZQiM4nYR/ij3KNJtt8jPouY9Y8Bw62cs6MLnZFNIvCWQ3nX2oD BTnA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=HTAsQBv1; 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.10; Sat, 05 Sep 2020 10:33:10 -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=HTAsQBv1; 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 S1728580AbgIERdF (ORCPT + 6 others); Sat, 5 Sep 2020 13:33:05 -0400 Received: from mail.kernel.org ([198.145.29.99]:60460 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728459AbgIERcp (ORCPT ); Sat, 5 Sep 2020 13:32:45 -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 1FE7D20760; Sat, 5 Sep 2020 17:32:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1599327165; bh=3VEbxW/JWesur5P76EKWlc6CVFWvzP9iSLLTM79UxgY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=HTAsQBv1w6Nl93W/C6lzeHKZ3ADXBRUu7MGBMKVc3kmv7tEwAW3YJMESvuNq9f3rH 0bk9nG5TnF9ChVfKC39N59jW44vKOufZ0eT9v2P7tpOtJU0R25fk2ErewuN/j3P5yP 9ItiHkHxYfP6452gFH1HARAi1GkAEPCNl5O352b8= From: Jonathan Cameron To: linux-iio@vger.kernel.org, Rob Herring , devicetree@vger.kernel.org Cc: Jonathan Cameron , Phani Movva Subject: [PATCH 13/20] dt-bindings:iio:adc:cosmic,10001-adc yaml conversion Date: Sat, 5 Sep 2020 18:29:57 +0100 Message-Id: <20200905173004.216081-14-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 I don't really know much about this one, hence the binding is a simple conversion of what was in the txt file. Signed-off-by: Jonathan Cameron Cc: Phani Movva --- .../bindings/iio/adc/cc10001_adc.txt | 22 ------- .../bindings/iio/adc/cosmic,10001-adc.yaml | 59 +++++++++++++++++++ 2 files changed, 59 insertions(+), 22 deletions(-) -- 2.28.0 diff --git a/Documentation/devicetree/bindings/iio/adc/cc10001_adc.txt b/Documentation/devicetree/bindings/iio/adc/cc10001_adc.txt deleted file mode 100644 index 904f76de9055..000000000000 --- a/Documentation/devicetree/bindings/iio/adc/cc10001_adc.txt +++ /dev/null @@ -1,22 +0,0 @@ -* Cosmic Circuits - Analog to Digital Converter (CC-10001-ADC) - -Required properties: - - compatible: Should be "cosmic,10001-adc" - - reg: Should contain adc registers location and length. - - clock-names: Should contain "adc". - - clocks: Should contain a clock specifier for each entry in clock-names - - vref-supply: The regulator supply ADC reference voltage. - -Optional properties: - - adc-reserved-channels: Bitmask of reserved channels, - i.e. channels that cannot be used by the OS. - -Example: -adc: adc@18101600 { - compatible = "cosmic,10001-adc"; - reg = <0x18101600 0x24>; - adc-reserved-channels = <0x2>; - clocks = <&adc_clk>; - clock-names = "adc"; - vref-supply = <®_1v8>; -}; diff --git a/Documentation/devicetree/bindings/iio/adc/cosmic,10001-adc.yaml b/Documentation/devicetree/bindings/iio/adc/cosmic,10001-adc.yaml new file mode 100644 index 000000000000..313a3b9642f9 --- /dev/null +++ b/Documentation/devicetree/bindings/iio/adc/cosmic,10001-adc.yaml @@ -0,0 +1,59 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/iio/adc/cosmic,10001-adc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Cosmic Circuits CC-10001 ADC + +maintainers: + - Phani Movva + +description: + Cosmic Circuits 10001 10-bit ADC device. + +properties: + compatible: + const: cosmic,10001-adc + + reg: + maxItems: 1 + + adc-reserved-channels: + $ref: /schemas/types.yaml#/definitions/uint32 + description: + Bitmask of reserved channels, i.e. channels that cannot be + used by the OS. + + clocks: + maxItems: 1 + + clock-names: + const: adc + + vref-supply: true + + "#io-channel-cells": + const: 1 + + +required: + - compatible + - reg + - clocks + - clock-names + - vref-supply + +additionalProperties: false + +examples: + - | + adc@18101600 { + compatible = "cosmic,10001-adc"; + reg = <0x18101600 0x24>; + adc-reserved-channels = <0x2>; + clocks = <&adc_clk>; + clock-names = "adc"; + vref-supply = <®_1v8>; + }; +...