Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp3435438rdb; Sun, 10 Dec 2023 05:49:49 -0800 (PST) X-Google-Smtp-Source: AGHT+IFhZo49CED/4/2G511dad7zGXbzRbNE1YtMZqg7J6fbEq2y/JrYOsXf2d4g0KukRqKxdYbq X-Received: by 2002:a05:6a20:561a:b0:18c:4f:ce9e with SMTP id ir26-20020a056a20561a00b0018c004fce9emr3522217pzc.43.1702216189658; Sun, 10 Dec 2023 05:49:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702216189; cv=none; d=google.com; s=arc-20160816; b=QTGFeopTFCxu+7UPI+ZzjDjYJgzri1ZnES4i/8wHBqaMqlPL+EWZyoO/XK4sH9dB7R aUG8bL92DzTaFwCUUbfZw56I9oQYN5IYrg8mA3z2AyriUwGsixHvELBvG+Dmkv/xjbYF HcQqpCSULOqEelv7ihASwEIfHFReOZHO982XBx9vqOYK7NdwsVoMbpAMVJmsUNEq9YyS rmG//4466WcJ+Pii7vXA+Uw02lD8ht4+ewNWdPRCezUUBipMeZcOFaaC29gzEJEnNrRK 5xJA2UeBWrbKxzy8LcgHwNNV7qynu6V5gZg3Ro4MKRCQ29oWk9k4hhCbMCTEam6Ai6+/ ad6Q== 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:subject:cc:to:from:date :dkim-signature; bh=ylXdyUjhG2Vm2uDULymQN/G7bFPTbO2GbpnK9YvR6fM=; fh=H6m5eqhL9pqAJQfFTTofiSr4ulk3Oyj3O7E0syiPS/k=; b=cqR77CIzx4p2RIbgiChWsk7CkQsQDmXVdh+Gwx/SZgPtA+0gqfrqk9ByKMyxZJQbjN hLUKcpObnl9B0Toz2pbXZEtJ9UdWVMUi0PDzFzuZhqPVaxcoaNIRl4m11iepmjnMQxTt A3xYWQ38YPViPiX1quvhlZVOUxyY2JSJGEnI57UGNUuaUkpnP9pczPD3lYorXN5xPOgd OIQq0Xmepe3ZtSQL6+pGX4S9su0tk7VJkuzFkpwFnkM0WBkEfr+XL10YExxpFYxSr1WP bP7HdXpea55ZvQBEnRyXWYvgxmNeEd+t0ywr0CAS3WmEoINnhJo6tN2A1Da9XaETj72X XvUA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=CqVhAuj7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from pete.vger.email (pete.vger.email. [23.128.96.36]) by mx.google.com with ESMTPS id 6-20020a630f46000000b005c6251da182si4516609pgp.226.2023.12.10.05.49.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 Dec 2023 05:49:49 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) client-ip=23.128.96.36; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=CqVhAuj7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id B0F698051623; Sun, 10 Dec 2023 05:49:46 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232347AbjLJNtd (ORCPT + 99 others); Sun, 10 Dec 2023 08:49:33 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53876 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229584AbjLJNtc (ORCPT ); Sun, 10 Dec 2023 08:49:32 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 15388B3 for ; Sun, 10 Dec 2023 05:49:39 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B59B8C433C8; Sun, 10 Dec 2023 13:49:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1702216178; bh=1XDcde1nT6h/mhKX1U8yI+hFvRKUQSwKWXMpIAW718Q=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=CqVhAuj7HtHzXxwYzJ8KKGtJY5m9gO88bSyziTt3Cd3WpB53sdy4YuC5/KI3HA4X+ 5ZUrgHB52fdsNzE9sdGyMIhqEmTMyIKRv/doimHOdlyCEjb2AOCiGhR1zsDJXV0JrP yD2dLL1rTtsdB9d1dA9XUsHRx5tTacSX6q8NrCelzsfsIB4LLYFNvdjwSxe55ytKz+ 6DDe1Kg2ZzjRqyfHTA4EYV+w7MFydplhYL8zeCMrZWZsJVQ/GhSlZGAD+eeBEG+nSl TrbeCwRCgyDKBrnJtYcwC6XBOnzhoRtKkPuqfEdcwOL/XuwvVgIM5GMgvoX3Zp3LrN 1B9NCnJKqZcwg== Date: Sun, 10 Dec 2023 13:49:32 +0000 From: Jonathan Cameron To: David Lechner Cc: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, Rob Herring , Krzysztof Kozlowski , Conor Dooley , Michael Hennerich , Nuno =?UTF-8?B?U8Oh?= , Alexandru Ardelean , Liam Girdwood , Mark Brown , linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/2] dt-bindings: iio: adc: Add binding for AD7380 ADCs Message-ID: <20231210134932.0bb429f1@jic23-huawei> In-Reply-To: <20231208-ad7380-mainline-v1-1-2b33fe2f44ae@baylibre.com> References: <20231208-ad7380-mainline-v1-0-2b33fe2f44ae@baylibre.com> <20231208-ad7380-mainline-v1-1-2b33fe2f44ae@baylibre.com> X-Mailer: Claws Mail 4.2.0 (GTK 3.24.38; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Sun, 10 Dec 2023 05:49:46 -0800 (PST) On Fri, 8 Dec 2023 09:51:40 -0600 David Lechner wrote: > This adds a binding specification for the Analog Devices Inc. AD7380 > family of ADCs. > > Signed-off-by: David Lechner Hi David, Comments inline. A question for Mark Brown on the 2-wire bit.. Do we have existing DT bindings for devices with parallel spi data outputs? > --- > .../devicetree/bindings/iio/adc/adi,ad7380.yaml | 102 +++++++++++++++++++++ > MAINTAINERS | 9 ++ > 2 files changed, 111 insertions(+) > > diff --git a/Documentation/devicetree/bindings/iio/adc/adi,ad7380.yaml b/Documentation/devicetree/bindings/iio/adc/adi,ad7380.yaml > new file mode 100644 > index 000000000000..e9a0b72cd9d3 > --- /dev/null > +++ b/Documentation/devicetree/bindings/iio/adc/adi,ad7380.yaml ... > + * https://www.analog.com/en/products/ad7380.html > + * https://www.analog.com/en/products/ad7381.html > + * https://www.analog.com/en/products/ad7383.html > + * https://www.analog.com/en/products/ad7384.html > + adi,sdo-mode: > + $ref: /schemas/types.yaml#/definitions/string > + enum: [ 1-wire, 2-wire ] > + description: > + In 1-wire mode, the SDOA pin acts as the sole data line and the SDOB/ALERT > + pin acts as the ALERT interrupt signal. In 2-wire mode, data for input A > + is read from SDOA and data for input B is read from SDOB/ALERT (and the > + ALERT interrupt signal is not available). This is fun... If I understand correctly 2-wire requires two SPI buses (or a complex spi controller that does parallel serial channels). What would description for that look like in DT and can we not establish what is wanted here from that bus description rather than an adi specific property? Seems a bit like parallel-memories. Mark, any insights into what we should do to describe this? > + > + vcc-supply: > + description: A 3V to 3.6V supply that powers the chip. > + > + vlogic-supply: > + description: > + A 1.65V to 3.6V supply for the logic pins. > + > + refio-supply: > + description: > + A 2.5V to 3.3V supply for the external reference voltage. When omitted, > + the internal 2.5V reference is used. > + > + interrupts: > + description: > + When the device is using 1-wire mode, this property is used to optionally > + specify the ALERT interrupt. > + maxItems: 1 > + > +required: > + - compatible > + - reg > + - adi,sdo-mode Could define a default of 1-wire? Simplifies things a little in the bindings. > + - vcc-supply > + - vlogic-supply