From patchwork Sun Mar 14 18:15:10 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 400108 Delivered-To: patch@linaro.org Received: by 2002:a02:8562:0:0:0:0:0 with SMTP id g89csp2840923jai; Sun, 14 Mar 2021 11:18:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyQRcJstNPMH0QP0nXlEj3DUut26Dh0C3OWQZhMS+ZnuyqulDubLXybYcN199vJWjks2cqc X-Received: by 2002:a17:906:32da:: with SMTP id k26mr19647987ejk.483.1615745925764; Sun, 14 Mar 2021 11:18:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1615745925; cv=none; d=google.com; s=arc-20160816; b=z1t6aHDydr9PtRn0KcgQlptLDphVrhoX+rMIsOxp/lqXKgywrAMPWMAxUKWGYRwQ6Y eSQyPOE7pUB50SNr1FgXgZ0N7ktUDrN9Id4RXyDy9UayO712BeyUfoALdTUEC5pNcLkN DIUgQ+20yLEZcjE3TDyBSIQL+yBTSY54u9T0J9AHi7GZOzW4ZlRNmvfVbRnX7VuEQVPM aLJiNl7WG2JcDcNHXlng7gsTZTvm4h5NV/vybUJj8CZI54eR5PBj+QEUhAflEbCAlwFm Ppd7pSlx9HYcpZ7NrH0T/s1XEfWRUuHe8HE0theS9S413RSPvgIaujVo7T8uTTJk6Tpi r0YA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=501Ylfv4C5orQoTxUahD3XXPa0KRnOFE2hQOycnFj7Q=; b=YV65xsvvL1Jb/4IVu1BDoLD0i119voQFzjkFEQhUqBfJTmCm6yV9Qdd9Ekby3zpKNz mDwkshePH1eKRcfB/hD+cfVRMN9ldR7bhGVqkEYQV03eSeUrj5Nz5Xm/7z1nhlcZgBYy iXeZanlI1785b7TF1ourqT/cIgT04aeRo518WrngOBSdZZcAriapCEUb5ZLgxMVTJ/Xl NjzHWTSFiiT7SlH6bONxiv03BsAE1/+aIb6DMEQI7y5QLPFRR2Np8BFCCtYoE5CA5PZ+ n25SouMV+cfs7az3a0I38+ACaMyKacemNJWxue624kNyVPogN2ViyxUEjaFxH+vmK2NH ybZw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ovP46vG6; 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 j7si9398976ejm.408.2021.03.14.11.18.45; Sun, 14 Mar 2021 11:18:45 -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=k20201202 header.b=ovP46vG6; 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 S234065AbhCNSSN (ORCPT + 6 others); Sun, 14 Mar 2021 14:18:13 -0400 Received: from mail.kernel.org ([198.145.29.99]:45340 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234060AbhCNSSI (ORCPT ); Sun, 14 Mar 2021 14:18:08 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 8417164EE2; Sun, 14 Mar 2021 18:18:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1615745888; bh=ivoStxHayDObgJdCDz7yp1aoi+PiXjUWhK3ZgLGEj70=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ovP46vG6dvjKP3OAJEDhFzu5gSeyKUXa74zwQ0z3wrLK6x/ab+aeZ6HdRsP7JTbnS +XHvs6ip0oJL7OxzjBAdi0B4Jk78Nsy4cuQBQxmiff7QRc/iE6YOfjVPCboxpWuYi7 WrsgE3cV246Ve5SM1tQqeYWr/V7IQ/NzS9vgpIUTy8qZm8HPZHS7hPQkFrPzr9HSCm iJrR60t0KyMPiTfyGsD7GicVrzs/HgFmBXq12cOlMuIyuMy+r3K8vZeY7Z7J8PzILG +ygobOURNnvUnEt1Rd+wcSh9lZhRSwbqLgYpLvxd0aNPd1A9f3sEhLxZU4GJa9+LPI x397UEpP2/eVA== From: Jonathan Cameron To: linux-iio@vger.kernel.org Cc: Lars-Peter Clausen , Michael Hennerich , Alexandru Ardelean , Robh+dt@kernel.org, Alexandru Ardelean , Jonathan Cameron , devicetree@vger.kernel.org Subject: [PATCH v2 23/24] dt-bindings:iio:cdc:adi,ad7150 binding doc Date: Sun, 14 Mar 2021 18:15:10 +0000 Message-Id: <20210314181511.531414-24-jic23@kernel.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210314181511.531414-1-jic23@kernel.org> References: <20210314181511.531414-1-jic23@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Jonathan Cameron Binding covering the ad7150, ad7151 and ad7156 capacitance to digital convertors. The only difference between these is how many channels they have (1 or 2) Whilst it is clearly necessary to provide power to the part, we don't need to know the voltage or anything so if it is always on, there should be no need to have it specified in the binding. Signed-off-by: Jonathan Cameron Cc: Robh+dt@kernel.org Cc: devicetree@vger.kernel.org Link: https://lore.kernel.org/r/20210207154623.433442-22-jic23@kernel.org --- .../bindings/iio/cdc/adi,ad7150.yaml | 69 +++++++++++++++++++ 1 file changed, 69 insertions(+) -- 2.30.2 Reviewed-by: Rob Herring diff --git a/Documentation/devicetree/bindings/iio/cdc/adi,ad7150.yaml b/Documentation/devicetree/bindings/iio/cdc/adi,ad7150.yaml new file mode 100644 index 000000000000..2155d3f5666c --- /dev/null +++ b/Documentation/devicetree/bindings/iio/cdc/adi,ad7150.yaml @@ -0,0 +1,69 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/iio/cdc/adi,ad7150.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Analog device AD7150 and similar capacitance to digital convertors. + +maintainers: + - Jonathan Cameron + +properties: + compatible: + enum: + - adi,ad7150 + - adi,ad7151 + - adi,ad7156 + + reg: + maxItems: 1 + + vdd-supply: true + + interrupts: true + +allOf: + - if: + properties: + compatible: + contains: + enum: + - adi,ad7150 + - adi,ad7156 + then: + properties: + interrupts: + minItems: 2 + maxItems: 2 + - if: + properties: + compatible: + contains: + const: adi,ad7151 + then: + properties: + interrupts: + minItems: 1 + maxItems: 1 + +required: + - compatible + - reg + +additionalProperties: false + +examples: + - | + i2c { + #address-cells = <1>; + #size-cells = <0>; + + cdc@48 { + compatible = "adi,ad7150"; + reg = <0x48>; + interrupts = <25 2>, <26 2>; + interrupt-parent = <&gpio>; + }; + }; +...