Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1243405imu; Sat, 17 Nov 2018 20:27:29 -0800 (PST) X-Google-Smtp-Source: AJdET5fiYZWA6OQVKITn8jZbDgSs6D60OILfQjue7Ozd13+FKcij86J8ZNAeFlPD3WxrIR5W9w2H X-Received: by 2002:a63:741:: with SMTP id 62mr15166980pgh.352.1542515249508; Sat, 17 Nov 2018 20:27:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542515249; cv=none; d=google.com; s=arc-20160816; b=U24MC0L8UWjDA8kYiG4mRGw1AbLqPUmcQwaqHtEkwyEuMc3gQl8jQSDbpzcbuOAFVg ob40V/TK8j/nYBxcqCuoCETxeQgaycaBGF+2iJNrpX9aKisb6BtNJtqFcumR+kxuUQ3S CiWhR6BisDn7nCiuSKs7UyAEhGULFAVtXALZLFhRO403ltkDhUC4JCFZtUEA291Ml2EJ a8dx8n8D6rMq58w95nrjBhKtCcLHgV2Wj7FOASGho0g8C7qx6mZcBPKU8dV2F9EdvDZw N4vWSrDn9ci9KCh6uu/H6t7g5k3AW1oRoS1dLJOyVRWP9NxwjEKcwXPZTo0U3Pq+fZVV SMmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=LbTCHeHGilCnfPYHT4tj0WlGCcK4WPxi/1Koox5eezY=; b=WXASsOm4PDWVLcdIUj1bqGrWSAOqWYJ8J1Z5HfemW+9mwBMglkpajNOe4kbRlVHDiZ WGVfEINUBbGzns5DiQc+MhFOETU3rsLyu3Iw2HNWuRQAONjR46n7TBs1UnqFtFjlwYCX /+VXkUtlZXqaKE+6eHKoa7LiGFVDmj8EJnT1V8mY3DoKVrH5mz7Gsd6JuITGxQJqaD3x nuZUVQzebnsp1mjxaRYRma2Oc84x9xYIIqFc944rzSHLjrhn1QxST8KgMGt8669YbDyt +hKJeAnZQpz3bjXmhvlRSo6F1J8vJ7JEPkIAdGPerpv/jVjfdNmz20K4e8WWlAMwPZw0 7opA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@usp-br.20150623.gappssmtp.com header.s=20150623 header.b=TTYvO4L9; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=usp.br Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x6si3331945pln.425.2018.11.17.20.27.15; Sat, 17 Nov 2018 20:27:29 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@usp-br.20150623.gappssmtp.com header.s=20150623 header.b=TTYvO4L9; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=usp.br Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727080AbeKROp3 (ORCPT + 99 others); Sun, 18 Nov 2018 09:45:29 -0500 Received: from mail-qk1-f194.google.com ([209.85.222.194]:40892 "EHLO mail-qk1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727038AbeKROp2 (ORCPT ); Sun, 18 Nov 2018 09:45:28 -0500 Received: by mail-qk1-f194.google.com with SMTP id y16so43866254qki.7 for ; Sat, 17 Nov 2018 20:26:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=usp-br.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=LbTCHeHGilCnfPYHT4tj0WlGCcK4WPxi/1Koox5eezY=; b=TTYvO4L9TcRHBUUw2NnvzLiUiM3++li0s4a7l/VOBv/6bAH987r2kgUZTvtYFJumC1 UZy91qqULKSAqYS7er192QUFA+Ti3kKn4PrCqc0WRTkFrTOWJWHNPbqVuQdONeZRt4mT pdxQI3CpZMm854UoKowpiJdiRQAmw6WGn0HKrTwxKQCASX9MYIJ/aPQo/VydLkvaGyaB ea4PCOASYqGNHsYBnkuS64WMIG4TqlTdaDu/M0OH342KyoOw6IfvjlVAYQTWzmnn+WKC CJ2GvZKGI+S+FypjbCpeSdslYANH4uAI3ZoIOfVykmAUNS6HqYd5R8T9gB+uVbNCTIjB T78A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=LbTCHeHGilCnfPYHT4tj0WlGCcK4WPxi/1Koox5eezY=; b=uY6lKsWyJEq63e0E1gRhEYf3qvEXksOLUvFmhe83EzwKw4kje0Knu9hmhwqrzU9TmP 0W2bkql0qJtaSdcwh0p7SxSemQBnSoDGjr4IIIYlxo3Og8bHu+bm1amj/L0ze86CdOIF uiw8N3jJ6UoHuOm4jL+IYR0mDvvwAmMcu6w7Eo9ki2Va0u86pW5k2e0eenF7ttMFpmsk izR7M/TzY4gbM86YoSBaPl8gBRcYmAhSwcbzOT9Gfs9yTJVZPxzjefG6ufsZ0PPNbNGL sN66YrEcclcU44CKs5nSbJQ3nBjXoDq8Zw1rQUsQGM+sz27JwsxuKcRQHa8MmTuc6YPW CpbQ== X-Gm-Message-State: AGRZ1gJ99BZe0gA4tlV/qCr4PwGyHmnwl6hVZURoBrtVUt7TFN8Y9sgj DVgx9luQlD7BNJxboPp18t/MCQ== X-Received: by 2002:ac8:22ca:: with SMTP id g10mr16745011qta.105.1542515187492; Sat, 17 Nov 2018 20:26:27 -0800 (PST) Received: from mango.spo.virtua.com.br ([2804:14c:81:942d::1]) by smtp.gmail.com with ESMTPSA id b6sm16112350qtq.29.2018.11.17.20.26.23 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 17 Nov 2018 20:26:27 -0800 (PST) From: Matheus Tavares To: Lars-Peter Clausen , Michael Hennerich , Jonathan Cameron , Hartmut Knaack , Peter Meerwald-Stadler , Greg Kroah-Hartman , Rob Herring , Mark Rutland Cc: linux-iio@vger.kernel.org, devel@driverdev.osuosl.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Alexandru Ardelean , kernel-usp@googlegroups.com, victorcolombo@gmail.com Subject: [PATCH v2 4/7] dt-bindings:iio:resolver: Add docs for ad2s90 Date: Sun, 18 Nov 2018 02:25:37 -0200 Message-Id: <20181118042540.12697-5-matheus.bernardino@usp.br> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20181118042540.12697-1-matheus.bernardino@usp.br> References: <20181118042540.12697-1-matheus.bernardino@usp.br> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patch adds the device tree binding documentation for the ad2s90 resolver-to-digital converter. Signed-off-by: Matheus Tavares --- Changes in v2: - Rewritten 'spi-cpol and spi-cpha' item to say that the device can work in either mode (0,0) or (1,1) and explain how they should be specified in DT. .../bindings/iio/resolver/ad2s90.txt | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 Documentation/devicetree/bindings/iio/resolver/ad2s90.txt diff --git a/Documentation/devicetree/bindings/iio/resolver/ad2s90.txt b/Documentation/devicetree/bindings/iio/resolver/ad2s90.txt new file mode 100644 index 000000000000..594417539938 --- /dev/null +++ b/Documentation/devicetree/bindings/iio/resolver/ad2s90.txt @@ -0,0 +1,28 @@ +Analog Devices AD2S90 Resolver-to-Digital Converter + +https://www.analog.com/en/products/ad2s90.html + +Required properties: + - compatible: should be "adi,ad2s90" + - reg: SPI chip select number for the device + - spi-max-frequency: set maximum clock frequency, must be 830000 + - spi-cpol and spi-cpha: + Either SPI mode (0,0) or (1,1) must be used, so specify none or both of + spi-cpha, spi-cpol. + +Note about max frequency: + Chip's max frequency, as specified in its datasheet, is 2Mhz. But a 600ns + delay is expected between the application of a logic LO to CS and the + application of SCLK, as also specified. And since the delay is not + implemented in the spi code, to satisfy it, SCLK's period should be at most + 2 * 600ns, so the max frequency should be 1 / (2 * 6e-7), which gives + roughly 830000Hz. + +Example: +resolver@0 { + compatible = "adi,ad2s90"; + reg = <0>; + spi-max-frequency = <830000>; + spi-cpol; + spi-cpha; +}; -- 2.18.0