From patchwork Fri Dec 9 14:15:14 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Benjamin Gaignard X-Patchwork-Id: 87486 Delivered-To: patch@linaro.org Received: by 10.140.20.101 with SMTP id 92csp328396qgi; Fri, 9 Dec 2016 06:16:47 -0800 (PST) X-Received: by 10.98.16.132 with SMTP id 4mr84737063pfq.163.1481293007295; Fri, 09 Dec 2016 06:16:47 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u62si34028553pgc.183.2016.12.09.06.16.47; Fri, 09 Dec 2016 06:16:47 -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=@linaro.org; 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=pass (p=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933337AbcLIOQ3 (ORCPT + 25 others); Fri, 9 Dec 2016 09:16:29 -0500 Received: from mail-wm0-f48.google.com ([74.125.82.48]:36548 "EHLO mail-wm0-f48.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932765AbcLIOQ0 (ORCPT ); Fri, 9 Dec 2016 09:16:26 -0500 Received: by mail-wm0-f48.google.com with SMTP id g23so28280718wme.1 for ; Fri, 09 Dec 2016 06:16:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=YR9Vb5HGJUjpifr3Uk6lzKwcbSkDrS+IMPspec3oD08=; b=eCaDL5d93xx9PMaJDBQGfOzMpXvSLjAr4AOGrD/K4XDyp84W4JUs6IsEeTZ/TkDENm S5SFWQw9VKWSDhc1WLJTXcKQxQRXe7/IJJXaTVTvBLQHUYMx+n7kjhvCBcgHzf0TzbY/ ObukDIqJzWfC8UMnb0UqY/PxCToRvqN7Ocub4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=YR9Vb5HGJUjpifr3Uk6lzKwcbSkDrS+IMPspec3oD08=; b=Deq2dC6dh2q0YTJXY0Zu/KY416TFKkomdBgAOVA24BtBgaripeRs9RTWDvt5ekXFht CEO2EEc0Cbd0IC8zrhY+PuX8rjGbtfbLsN+CIS5lrIro12JWSOsRmTRHS6s2vvxxtxu9 TdzUwWnRlPyMBmpQ7RWf9KRIAU0/j52kkm6a3o3y9F8w/22n/RhF4J5AK5ULvceurcxJ Sfwv0xBrTV24EwNDiwI0m5cpIKou+mOBCvoxdDO1vXBsynsfrbm0bnmnp6Yp2i82NyUW MKjxzHHGQxJn6Nq407YmlQahwSHuCqRB3ed4MJGNHtir4+fWed1U6E0g2BRAqvP2OfyX ThGg== X-Gm-Message-State: AKaTC03qo0PXRqOUrTKVLs71yiSeubdaOl1vwx4mvi3jwpaUZlFtlHulOMbs+lAzTAaR8NXO X-Received: by 10.28.105.81 with SMTP id e78mr7502673wmc.140.1481292984949; Fri, 09 Dec 2016 06:16:24 -0800 (PST) Received: from lmenx321.st.com. ([80.215.96.58]) by smtp.gmail.com with ESMTPSA id j6sm42589344wjk.25.2016.12.09.06.16.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 09 Dec 2016 06:16:24 -0800 (PST) From: Benjamin Gaignard X-Google-Original-From: Benjamin Gaignard To: lee.jones@linaro.org, robh+dt@kernel.org, mark.rutland@arm.com, alexandre.torgue@st.com, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, thierry.reding@gmail.com, linux-pwm@vger.kernel.org, jic23@kernel.org, knaack.h@gmx.de, lars@metafoo.de, pmeerw@pmeerw.net, linux-iio@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: fabrice.gasnier@st.com, gerald.baeza@st.com, arnaud.pouliquen@st.com, linus.walleij@linaro.org, linaro-kernel@lists.linaro.org, benjamin.gaignard@linaro.org, Benjamin Gaignard Subject: [PATCH v6 3/8] PWM: add pwm-stm32 DT bindings Date: Fri, 9 Dec 2016 15:15:14 +0100 Message-Id: <1481292919-26587-4-git-send-email-benjamin.gaignard@st.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1481292919-26587-1-git-send-email-benjamin.gaignard@st.com> References: <1481292919-26587-1-git-send-email-benjamin.gaignard@st.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Define bindings for pwm-stm32 version 6: - change st,breakinput parameter format to make it usuable on stm32f7 too. version 2: - use parameters instead of compatible of handle the hardware configuration Signed-off-by: Benjamin Gaignard --- .../devicetree/bindings/pwm/pwm-stm32.txt | 33 ++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 Documentation/devicetree/bindings/pwm/pwm-stm32.txt -- 1.9.1 Acked-by: Rob Herring diff --git a/Documentation/devicetree/bindings/pwm/pwm-stm32.txt b/Documentation/devicetree/bindings/pwm/pwm-stm32.txt new file mode 100644 index 0000000..866f222 --- /dev/null +++ b/Documentation/devicetree/bindings/pwm/pwm-stm32.txt @@ -0,0 +1,33 @@ +STMicroelectronics STM32 Timers PWM bindings + +Must be a sub-node of an STM32 Timers device tree node. +See ../mfd/stm32-timers.txt for details about the parent node. + +Required parameters: +- compatible: Must be "st,stm32-pwm". +- pinctrl-names: Set to "default". +- pinctrl-0: List of phandles pointing to pin configuration nodes for PWM module. + For Pinctrl properties see ../pinctrl/pinctrl-bindings.txt + +Optional parameters: +- st,breakinput: Arrays of three u32 to describe break input configurations. + "index" indicates on which break input the configuration should be applied. + "level" gives the active level (0=low or 1=high) for this configuration. + "filter" gives the filtering value to be applied. + +Example: + timers@40010000 { + #address-cells = <1>; + #size-cells = <0>; + compatible = "st,stm32-timers"; + reg = <0x40010000 0x400>; + clocks = <&rcc 0 160>; + clock-names = "clk_int"; + + pwm { + compatible = "st,stm32-pwm"; + pinctrl-0 = <&pwm1_pins>; + pinctrl-names = "default"; + st,breakinput = <0 1 5>; + }; + };