From patchwork Tue Jan 8 08:41:29 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Ben Whitten X-Patchwork-Id: 1021780 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming-netdev@ozlabs.org Delivered-To: patchwork-incoming-netdev@ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=netdev-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="uHFaYa20"; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 43Ym3n4gs7z9sND for ; Tue, 8 Jan 2019 19:42:45 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727745AbfAHImT (ORCPT ); Tue, 8 Jan 2019 03:42:19 -0500 Received: from mail-pl1-f196.google.com ([209.85.214.196]:36919 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727446AbfAHImT (ORCPT ); Tue, 8 Jan 2019 03:42:19 -0500 Received: by mail-pl1-f196.google.com with SMTP id b5so1554630plr.4; Tue, 08 Jan 2019 00:42:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=qVZjZYFPLtmn4+3E+4YZCMQFpHfNrHKl9wLnRK94PSQ=; b=uHFaYa20MjnvDjmGcs7QV5yqwKagAtsyxBsj0Py+19GpAuYl8nbWyY8lPVou9VBXOH uLF8tLPpLU1EG4M3F2D4CHRInD1jsuvOAE6ldKtkbXUux2cxR/nwTdX9/EYpJP02l4zo 9fAdOFcXLaWsYKsLcAdxuyhZ+j15TVm13NgbIu8qGy37Nh6eGeyPnVRWKcNkzWIinbNj 7l6Ze4Ry+Eh+fQ4gaY6pDPSZzs9F9Wuf4ZTK0e4uXQv4qb86qr1qlTXP7Npn9HS1wTbW IWdH14UrfmZuwiyQFQryAcdzzoM+tC03BK32uxoQWXJ3uwiVCd6M5Tath9P0hXIfRol1 giYw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :mime-version:content-transfer-encoding; bh=qVZjZYFPLtmn4+3E+4YZCMQFpHfNrHKl9wLnRK94PSQ=; b=pqS5KMwZKESwjQfzS/63g2Gtkp/LaXCvrwVxhSGWrY4YWIVLJ/btPoBdZBtkjsnQCV kOPVTl+UyJg1KFlbR7u9xa8lnsgJVkiwgB6h1WmoFgO8T5LT1DIWlcFIP0GKGwQY89gV sKx2KnjoieK9SyU8O+jFYaxwMLB2rYOsEpV4M7Qe4YKfFCOE8Ol1ZSnFCmUNKVvcizbC 4mdPCgf+031s9f/9+XIJKpb/+vZzY9XnG9v92vUsPM70qW9a6oL61E+a2YnICTfS4J7B EJ/H3VzQ+FdL0niVQ8WTJwAz8MGsJmB/d/Ajj6UsScl8ewR0iBA5lGsUnRJvSVTQhSQq qs1g== X-Gm-Message-State: AJcUukdwsdGY7aCEVLMZo3YJrC1vZG8KDaxBwBpvVjwCU2uVkT27vIW6 4VKSIaPcQ4mwsD+oItUr9qE= X-Google-Smtp-Source: ALg8bN6DItOts/p7f74OcUXQedJQ9pEor4eHmEPTxhMWjdgSNG+X5j7IH2+DIq9h21Duiqsrg6zqqQ== X-Received: by 2002:a17:902:b093:: with SMTP id p19mr852477plr.135.1546936938260; Tue, 08 Jan 2019 00:42:18 -0800 (PST) Received: from localhost.localdomain (i121-116-192-145.s41.a020.ap.plala.or.jp. [121.116.192.145]) by smtp.gmail.com with ESMTPSA id l64sm86277445pge.73.2019.01.08.00.42.14 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 08 Jan 2019 00:42:17 -0800 (PST) From: Ben Whitten To: linux-lpwan@lists.infradead.org, afaerber@suse.de Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Ben Whitten , Rob Herring , Mark Rutland Subject: [PATCH lora-next 1/4] dt-bindings: lora: sx130x: add basic documentation Date: Tue, 8 Jan 2019 17:41:29 +0900 Message-Id: <20190108084132.10214-1-ben.whitten@gmail.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Add basic documentation in YAML format for the sx130x series concentrators from Semtech. Required is; the location on the SPI bus, the reset gpio and the node for downstream IQ radios, typically sx125x. Signed-off-by: Ben Whitten --- .../bindings/lora/semtech,sx130x.yaml | 87 +++++++++++++++++++ 1 file changed, 87 insertions(+) create mode 100644 Documentation/devicetree/bindings/lora/semtech,sx130x.yaml diff --git a/Documentation/devicetree/bindings/lora/semtech,sx130x.yaml b/Documentation/devicetree/bindings/lora/semtech,sx130x.yaml new file mode 100644 index 000000000000..ad263bc4e60d --- /dev/null +++ b/Documentation/devicetree/bindings/lora/semtech,sx130x.yaml @@ -0,0 +1,87 @@ +# SPDX-License-Identifier: GPL-2.0 +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/lora/semtech,sx130x.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Semtech LoRa concentrator + +maintainers: + - Andreas Färber + - Ben Whitten + +description: | + Semtech LoRa concentrator sx130x digital baseband chip is capable of + demodulating LoRa signals on 8 channels simultaneously. + + It is typically paired with two sx125x IQ radios controlled over an + SPI directly from the concentrator. + + The concentrator itself it controlled over SPI. + +properties: + compatible: + items: + - enum: + - semtech,sx1301 + - semtech,sx1308 + + reg: + maxItems: 1 + description: The chip select on the SPI bus. + + reset-gpios: + maxItems: 1 + description: A connection of the reset gpio line. + + spi-max-frequency: + maximum: 10000000 + default: 8000000 + description: The frequency of the SPI communication to the concentrator, + in Hz. Maximum SPI frequency is 10MHz although 8MHz is typically used + on a number of cards. + + radio-spi: + description: The concentrator has two radios connected which are contained + within the following node. + + properties: + '#address-cells': + const: 1 + + '#size-cells': + const: 0 + + required: + - '#address-cells' + - '#size-cells' + +required: + - compatible + - reg + - reset-gpios + - radio-spi + +examples: + - | + concentrator0: lora@0 { + compatible = "semtech,sx1301"; + reg = <0>; + reset-gpios = <&pioB 27 GPIO_ACTIVE_HIGH>; + spi-max-frequency = <8000000>; + + radio-spi { + #address-cells = <1>; + #size-cells = <0>; + + radio0: lora@0 { + compatible = "semtech,sx1257"; + reg = <0>; + }; + + radio1: lora@1 { + compatible = "semtech,sx1257"; + reg = <1>; + }; + }; + }; From patchwork Tue Jan 8 08:41:30 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Ben Whitten X-Patchwork-Id: 1021774 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming-netdev@ozlabs.org Delivered-To: patchwork-incoming-netdev@ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=netdev-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="l+2dUHhE"; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 43Ym3Q56XHz9sN8 for ; Tue, 8 Jan 2019 19:42:26 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727919AbfAHImX (ORCPT ); Tue, 8 Jan 2019 03:42:23 -0500 Received: from mail-pl1-f196.google.com ([209.85.214.196]:38146 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727446AbfAHImW (ORCPT ); Tue, 8 Jan 2019 03:42:22 -0500 Received: by mail-pl1-f196.google.com with SMTP id e5so1551352plb.5; Tue, 08 Jan 2019 00:42:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=KxcYoPKhPakJz2BJLRFHaSM8hqbnJhclkIWiFsvi1VI=; b=l+2dUHhEq+Q4MC+zH2KdpWjMZdQ21TFN6tue9X9sRI9bHwKvuXfLMCssLl5A7X+hyk ge50fOULWFLA4IIEqRc0HHrQjnQrFAwUSeqrZDIjxnWSw+gMNG3r2DG+XxAO+a8zwKZF rFg5UeO7DGaSVmZagunjl+87ybS5HNzovP0VoITQ0d2ayf/U/qLsM/UUsuJylSuM5XMw gprEBLJnBXvUBbvYEu5IdjgEQPgSLduruvKuHtzm+JknvZ7SuYG9fDgrLDSRsHoIhVo7 yt92l7xRHQjER6S7C3WW/cR5KP6F4p5I5niIwcgiivFRknkD4eUOXPZUIKAWwrV+sQrC oRyw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=KxcYoPKhPakJz2BJLRFHaSM8hqbnJhclkIWiFsvi1VI=; b=azSh5xYcsdwU9XyiuAaLs5VQwwd2CY+fn6JSqxffrOBGzEWySTtQgbZxH1Xnp29bkM PxOI6vGtGtgLf/MXqfo1rvb+aIxIUFuevodm0joWpUM4Ef5WnRzZc/wlX8ABWLvIgXyc m4L80H352hSarzrY3Hkh3SD8Vb9cVUvDwHwwAzoVeFwJFimO6uZmVRGL02oB7kid6XRA B8IoD+u3/deP4kLxiZPm4l+LNkMH1n8IsROPbv5synET3mV2CxOZu7o/mUP2DzJuFng7 NYcPb6BXEo1I9CwuHfwgZ8QxhFBEY/+sIgN0l8+1P0LwXafQnPBpA82yQubq3sER2WWe Kn9A== X-Gm-Message-State: AJcUukdwZPdgsq1GTdEuPlflC0JGC84FdWR8yMgebXJOQ0/TuoAuTmTB xPTgn23GOgTDvrzWtuOhk34= X-Google-Smtp-Source: ALg8bN6rXetocnBLKFzwq67DfykBN6x0L9AwLJqDDn+K30GmQx9vKNZ09hIpi4k1UZyRm31oW9dvOg== X-Received: by 2002:a17:902:9047:: with SMTP id w7mr877703plz.270.1546936941332; Tue, 08 Jan 2019 00:42:21 -0800 (PST) Received: from localhost.localdomain (i121-116-192-145.s41.a020.ap.plala.or.jp. [121.116.192.145]) by smtp.gmail.com with ESMTPSA id l64sm86277445pge.73.2019.01.08.00.42.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 08 Jan 2019 00:42:20 -0800 (PST) From: Ben Whitten To: linux-lpwan@lists.infradead.org, afaerber@suse.de Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Ben Whitten , Rob Herring , Mark Rutland Subject: [PATCH lora-next 2/4] dt-bindings: lora: sx125x: add basic documentation Date: Tue, 8 Jan 2019 17:41:30 +0900 Message-Id: <20190108084132.10214-2-ben.whitten@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190108084132.10214-1-ben.whitten@gmail.com> References: <20190108084132.10214-1-ben.whitten@gmail.com> MIME-Version: 1.0 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org The sx125x family are IQ radio transceivers from Semtech configured over SPI, they are typically connected to an sx130x series concentrator however may be connected to a host directly. Required properties include the radio number of the host or concentrator bus. Signed-off-by: Ben Whitten --- .../bindings/lora/semtech,sx125x.yaml | 45 +++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 Documentation/devicetree/bindings/lora/semtech,sx125x.yaml diff --git a/Documentation/devicetree/bindings/lora/semtech,sx125x.yaml b/Documentation/devicetree/bindings/lora/semtech,sx125x.yaml new file mode 100644 index 000000000000..5eadec860b70 --- /dev/null +++ b/Documentation/devicetree/bindings/lora/semtech,sx125x.yaml @@ -0,0 +1,45 @@ +# SPDX-License-Identifier: GPL-2.0 +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/lora/semtech,sx125x.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Semtech IQ modulator/de-modulator transeiver + +maintainers: + - Andreas Färber + - Ben Whitten + +description: | + The sx125x family are highly integrated RF front-end to digital I and Q + modulator/demodulator Multi-PHY mode transceiver capable of supporting + multiple constant and non-constant envelope modulation schemes. + +properties: + compatible: + items: + - enum: + - semtech,sx1255 + - semtech,sx1257 + - semtech,sx1258 + + reg: + maxItems: 1 + description: The chip select on the SPI bus or radio number in concentrator. + + spi-max-frequency: + maximum: 10000000 + default: 8000000 + description: The frequency of the SPI communication to the radio, + in Hz. Maximum SPI frequency is 10MHz. + +required: + - compatible + - reg + +examples: + - | + radio0: lora@0 { + compatible = "semtech,sx1257"; + reg = <0>; + }; From patchwork Tue Jan 8 08:41:31 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ben Whitten X-Patchwork-Id: 1021777 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming-netdev@ozlabs.org Delivered-To: patchwork-incoming-netdev@ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=netdev-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="EdgbTg/B"; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 43Ym3d6bj0z9sNB for ; Tue, 8 Jan 2019 19:42:37 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727997AbfAHIm0 (ORCPT ); Tue, 8 Jan 2019 03:42:26 -0500 Received: from mail-pl1-f196.google.com ([209.85.214.196]:32983 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727446AbfAHImZ (ORCPT ); Tue, 8 Jan 2019 03:42:25 -0500 Received: by mail-pl1-f196.google.com with SMTP id z23so1567849plo.0; Tue, 08 Jan 2019 00:42:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=zvlms/9Oh6c6viVVAzA5dTDzr6flDQdvl/myX+R22Es=; b=EdgbTg/BDZfiFIlYG4L0ZxnL24/LW3/vDFZ4CZzTtIpJhgds5XI2vcR+PiB5eqwtXw GQWi78TKypns6wHLQY5TNJGLVZ7aznuekWl2gIBMyfpvm78wyaV0HG7bcBzdzDLSFBUX Oou6FPlif2bTWxjLdU4vRSlnoqBOeQTgrKlqZ+dTpTzjr1tkrgYI0PpKEUAnVp/GtBG0 hmQQ5AeRbMjLik4z3smpI0BmGXkgmN8k3btZpSbgbNCSQstMMSMAqRO+jBS1DJApDI/h 2Natr7nzX/B40jdIZbGtBMM7fr22WYA1aOvbWDaqEfFm0YigDWGCmMKV7pwgkJ2OwNnw xKhQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=zvlms/9Oh6c6viVVAzA5dTDzr6flDQdvl/myX+R22Es=; b=g2ODtuUmy4fjbHhJl33qneMwC//ugedGM4mqjOU0x8miEzgxRU6GcIoQQwaRNiMeJR jyTh8Gm3Fr3Swpfh1PlISxx2dCYzvVDS49TYY2JqQOTOzjF+HE/F1gurwChEDUStA52x Pt5vfu+k0MO0pMHoDjEHhsKxexxwiqBbEh96CVD7Qv0oC+Jh7vjmzkSUPZVG+bcygDyj XEszyLpr6ansOOik84LiRy4mQZQWmFk5byYR9yJVp8BMucHqQqpHzK4k3B10i8m4jLkE vdP7B7v3qiq/PSKevlh0JcozA4i6zhi7Tia1Pgc9kpxS0LatbSc45EYL9OH5zgd+MK5k qz/A== X-Gm-Message-State: AJcUukez6dxqrESb1DqIyrtAYgPI0bodvfqmEUWRmE4Mi6x/WQ3wNZSk nMWle+eJi7erWMeNEAguYUY= X-Google-Smtp-Source: ALg8bN5msPM1uGIQkeQtDjYmwb+KJAJRLfgYu8ip6tekhqNyJPYDMon7Wzqxe9XSVnstlZRxgYukoA== X-Received: by 2002:a17:902:b592:: with SMTP id a18mr843823pls.293.1546936944596; Tue, 08 Jan 2019 00:42:24 -0800 (PST) Received: from localhost.localdomain (i121-116-192-145.s41.a020.ap.plala.or.jp. [121.116.192.145]) by smtp.gmail.com with ESMTPSA id l64sm86277445pge.73.2019.01.08.00.42.21 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 08 Jan 2019 00:42:23 -0800 (PST) From: Ben Whitten To: linux-lpwan@lists.infradead.org, afaerber@suse.de Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Ben Whitten , Rob Herring , Mark Rutland , "David S. Miller" Subject: [PATCH lora-next 3/4] dt-bindings: lora: sx125x: add clock bindings Date: Tue, 8 Jan 2019 17:41:31 +0900 Message-Id: <20190108084132.10214-3-ben.whitten@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190108084132.10214-1-ben.whitten@gmail.com> References: <20190108084132.10214-1-ben.whitten@gmail.com> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org The sx125x consumes a 32MHz clock and if it is coupled with a sx130x concentrator may also provide a gated version of this 32MHz for the concentrator. In the example we connect to output 0 of "txco" clock source. The radio also provides a single clock output, hence "#clock-cells = <0>", named "clk32m" for consumption by the sx130x concentrator. Signed-off-by: Ben Whitten --- .../{ => net}/lora/semtech,sx125x.yaml | 27 +++++++++++++++++++ 1 file changed, 27 insertions(+) rename Documentation/devicetree/bindings/{ => net}/lora/semtech,sx125x.yaml (67%) diff --git a/Documentation/devicetree/bindings/lora/semtech,sx125x.yaml b/Documentation/devicetree/bindings/net/lora/semtech,sx125x.yaml similarity index 67% rename from Documentation/devicetree/bindings/lora/semtech,sx125x.yaml rename to Documentation/devicetree/bindings/net/lora/semtech,sx125x.yaml index 5eadec860b70..c2fb4ac06341 100644 --- a/Documentation/devicetree/bindings/lora/semtech,sx125x.yaml +++ b/Documentation/devicetree/bindings/net/lora/semtech,sx125x.yaml @@ -33,13 +33,40 @@ properties: description: The frequency of the SPI communication to the radio, in Hz. Maximum SPI frequency is 10MHz. + clocks: + maxItems: 1 + description: 32MHz clock provider + + clock-names: + items: + - const: txco + + clock-output-names: + items: + - const: clk32m + description: 32MHz output clock name + + '#clock-cells': + const: 0 + required: - compatible - reg examples: - | + tcxo: dummy32m { + compatible = "fixed-clock"; + clock-frequency = <32000000>; + clock-output-names = "tcxo"; + #clock-cells = <0>; + }; + radio0: lora@0 { compatible = "semtech,sx1257"; reg = <0>; + clocks = <&tcxo 0>; + clock-names = "tcxo"; + clock-output-names = "clk32m"; + #clock-cells = <0>; }; From patchwork Tue Jan 8 08:41:32 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ben Whitten X-Patchwork-Id: 1021776 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming-netdev@ozlabs.org Delivered-To: patchwork-incoming-netdev@ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=netdev-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="pR9uYBn7"; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 43Ym3Z6zpgz9sMp for ; Tue, 8 Jan 2019 19:42:34 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728064AbfAHIma (ORCPT ); Tue, 8 Jan 2019 03:42:30 -0500 Received: from mail-pl1-f194.google.com ([209.85.214.194]:33867 "EHLO mail-pl1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727446AbfAHIm2 (ORCPT ); Tue, 8 Jan 2019 03:42:28 -0500 Received: by mail-pl1-f194.google.com with SMTP id w4so1557564plz.1; Tue, 08 Jan 2019 00:42:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=vkpcXAJnt5ax4aCurBUzxVNE0WIBxUcBalSzzt77+/4=; b=pR9uYBn7EvMQ5Pp7um0Q9+Yjl6ZWfZ8WywUMJSLz6CsBJRjK5slP5t7SmVjtgZaClv rYFWlD0REHgDWvy5o/Skk7dNwGAR7y5gGgQ7bCwydChiH/ggtGAPwQaJrACWpmqAMXSC nFqLpaUasMQEdBP2wDwfW3E1mGkp0OCMxD5f//ISFz2yi19oHN7Cf5yncytMTjjoYImS sWV6bHN6clr+Lpt/m0lyf2UZd/oDyQjm0z0/ptxa9k1y34sFpBETQtiDTRsNFF6ogROy EwZJtcGVK0vB0eFAZHStkDPsFY6N+adAtcnDEUssaeV4vKm4gbvixuH/q1fYpIf/LR/a hz4w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=vkpcXAJnt5ax4aCurBUzxVNE0WIBxUcBalSzzt77+/4=; b=Tk7xwqyqgsDq7pfXUy3zeicU0hODC8KuJHpVIVKM3jcnei4RvI67svTs4oSuZxR8M6 r0/EolfIDDZVYOCuKj0t1a1GhgMulxnEGbCbKvjWdtkRtHAXV/bEZ68kwVyFzqfvrcnY QsXZjvKnggLkJbfQxEiSIKRSQTsDX/2TouUJLv/6VEx6iH+4z/7mRXXA8U45RHqHhnEH c30wrHFlLoAC7fHn0UbJmiGjIxS7FUcGky/PZ2rjwVUZZVXHa+TKgrwViFMe4z+cBPiV trurlT3p3o8d+Mz0HMqkl/dfpXiDoeKR5xhjYvX4W0I3RzjWzN0ODKY94F0A7ejHAYHr 37Uw== X-Gm-Message-State: AJcUukfxxvc8/rL3RUvuPfw14DUok8kmY4qGSoeMpDy++iAva2No9tTB Fy1LYBwY1idmBZ6UBriPP8M= X-Google-Smtp-Source: ALg8bN6lAJvJzV4OXEErwxdDjXiWnNipx7aS9ErceYWL6lf30MS0W/Dwcc7t8/9q091waJmQjyvYsA== X-Received: by 2002:a17:902:b78b:: with SMTP id e11mr886728pls.90.1546936947815; Tue, 08 Jan 2019 00:42:27 -0800 (PST) Received: from localhost.localdomain (i121-116-192-145.s41.a020.ap.plala.or.jp. [121.116.192.145]) by smtp.gmail.com with ESMTPSA id l64sm86277445pge.73.2019.01.08.00.42.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 08 Jan 2019 00:42:27 -0800 (PST) From: Ben Whitten To: linux-lpwan@lists.infradead.org, afaerber@suse.de Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Ben Whitten , Rob Herring , Mark Rutland , "David S. Miller" Subject: [PATCH lora-next 4/4] dt-bindings: lora: sx130x: add clock bindings Date: Tue, 8 Jan 2019 17:41:32 +0900 Message-Id: <20190108084132.10214-4-ben.whitten@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190108084132.10214-1-ben.whitten@gmail.com> References: <20190108084132.10214-1-ben.whitten@gmail.com> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org The sx130x family consumes two clocks, a 32MHz clock provided by a connected IQ transceiver, and a 133MHz high speed clock. In the example we connect the concentrator to output 0 of a fixed clock providing the 133MHz high speed clock, and we connect to output 0 of a connected transceiver 32MHz clock. The connected radios are both fed from output 0 of a fixed 32MHz clock, with only one being the clock source back with one output to the sx130x concentrator. Signed-off-by: Ben Whitten --- .../{ => net}/lora/semtech,sx130x.yaml | 39 ++++++++++++++++++- 1 file changed, 38 insertions(+), 1 deletion(-) rename Documentation/devicetree/bindings/{ => net}/lora/semtech,sx130x.yaml (62%) diff --git a/Documentation/devicetree/bindings/lora/semtech,sx130x.yaml b/Documentation/devicetree/bindings/net/lora/semtech,sx130x.yaml similarity index 62% rename from Documentation/devicetree/bindings/lora/semtech,sx130x.yaml rename to Documentation/devicetree/bindings/net/lora/semtech,sx130x.yaml index ad263bc4e60d..23a096ca2912 100644 --- a/Documentation/devicetree/bindings/lora/semtech,sx130x.yaml +++ b/Documentation/devicetree/bindings/net/lora/semtech,sx130x.yaml @@ -15,7 +15,8 @@ description: | demodulating LoRa signals on 8 channels simultaneously. It is typically paired with two sx125x IQ radios controlled over an - SPI directly from the concentrator. + SPI directly from the concentrator. One of the radios will provide + a 32MHz clock back into the concentrator. The concentrator itself it controlled over SPI. @@ -41,6 +42,20 @@ properties: in Hz. Maximum SPI frequency is 10MHz although 8MHz is typically used on a number of cards. + clocks: + maxItems: 2 + items: + - description: 32MHz clock provider + - description: 133MHz high speed clock provider + description: The chip requires two clock inputs; A 32MHz clock at CMOS + level which is provided from a connected radio. + And a 133MHz high speed clock at CMOS level provided by an oscillator. + + clock-names: + items: + - const: clk32m + - const: clkhs + radio-spi: description: The concentrator has two radios connected which are contained within the following node. @@ -64,11 +79,27 @@ required: examples: - | + tcxo: dummy32m { + compatible = "fixed-clock"; + clock-frequency = <32000000>; + clock-output-names = "tcxo"; + #clock-cells = <0>; + }; + + clkhs: dummy133m { + compatible = "fixed-clock"; + clock-frequency = <133000000>; + clock-output-names = "clkhs"; + #clock-cells = <0>; + }; + concentrator0: lora@0 { compatible = "semtech,sx1301"; reg = <0>; reset-gpios = <&pioB 27 GPIO_ACTIVE_HIGH>; spi-max-frequency = <8000000>; + clocks = <&radio1 0>, <&clkhs 0>; + clock-names = "clk32m", "clkhs"; radio-spi { #address-cells = <1>; @@ -77,11 +108,17 @@ examples: radio0: lora@0 { compatible = "semtech,sx1257"; reg = <0>; + clocks = <&tcxo 0>; + clock-names = "tcxo"; }; radio1: lora@1 { compatible = "semtech,sx1257"; reg = <1>; + clocks = <&tcxo 0>; + clock-names = "tcxo"; + clock-output-names = "clk32m"; + #clock-cells = <0>; }; }; };