From patchwork Mon Nov 7 10:09:32 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pankaj Dubey X-Patchwork-Id: 9414623 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 9DF816022E for ; Mon, 7 Nov 2016 10:09:59 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8F14628AA1 for ; Mon, 7 Nov 2016 10:09:59 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 833D628B3D; Mon, 7 Nov 2016 10:09:59 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 02E2A28AA1 for ; Mon, 7 Nov 2016 10:09:59 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.85_2 #1 (Red Hat Linux)) id 1c3gqp-0006AL-Gj; Mon, 07 Nov 2016 10:08:27 +0000 Received: from mailout1.samsung.com ([203.254.224.24]) by bombadil.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1c3gpf-0005GR-QI for linux-arm-kernel@lists.infradead.org; Mon, 07 Nov 2016 10:07:18 +0000 Received: from epcpsbgm2new.samsung.com (epcpsbgm2 [203.254.230.27]) by mailout1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0OG901JPAO2XHN20@mailout1.samsung.com> for linux-arm-kernel@lists.infradead.org; Mon, 07 Nov 2016 19:06:40 +0900 (KST) X-AuditID: cbfee61b-f796f6d000004092-ef-582052305aee Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm2new.samsung.com (EPCPMTA) with SMTP id 9A.A8.16530.03250285; Mon, 7 Nov 2016 19:06:40 +0900 (KST) Received: from pankaj.sisodomain.com ([107.108.83.125]) by mmp1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OG90041ZO2UTC50@mmp1.samsung.com>; Mon, 07 Nov 2016 19:06:40 +0900 (KST) From: Pankaj Dubey To: linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH 2/6] dt-bindings: clk: max8997: Add DT binding documentation Date: Mon, 07 Nov 2016 15:39:32 +0530 Message-id: <1478513376-14307-3-git-send-email-pankaj.dubey@samsung.com> X-Mailer: git-send-email 2.7.4 In-reply-to: <1478513376-14307-1-git-send-email-pankaj.dubey@samsung.com> References: <1478513376-14307-1-git-send-email-pankaj.dubey@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFupkkeLIzCtJLcpLzFFi42I5/e+xgK5BkEKEwbbJmhbzj5xjtXjzdg2T Rf/j18wW589vYLfY9Pgaq8XHnnusFjPO72OyuHjK1eJ24wo2i0Vbv7BbtO49wm7RsYzRgcfj /Y1Wdo9NqzrZPDYvqffY0n+X3aNvyypGj8+b5ALYotxsMlITU1KLFFLzkvNTMvPSbZVCQ9x0 LZQU8hJzU22VInR9Q4KUFMoSc0qBPCMDNODgHOAerKRvl+CWMWnKF6aC3eIV89ZNZG9gvCPc xcjJISFgIrF3wnsWCFtM4sK99WxdjFwcQgJLGSVO9d5jgXB+MkqsP9TOClLFJqAr8eT9XGYQ W0TAW2Lymb/sIEXMAkuZJFY9+gs2SljAR+LmgoVsIDaLgKrE6ubJYDavgIfEoaN32CHWyUnc PNcJNohTwFPi84y1YDVCQDXrtm1gmcDIu4CRYRWjRGpBckFxUnquUV5quV5xYm5xaV66XnJ+ 7iZGcDQ8k97BeHiX+yFGAQ5GJR7eCU4KEUKsiWXFlbmHGCU4mJVEeFn9gEK8KYmVValF+fFF pTmpxYcYTYEOm8gsJZqcD4zUvJJ4QxNzE3NjAwtzS0sTIyVx3sbZz8KFBNITS1KzU1MLUotg +pg4OKUaGNNqXp6Yv/neKVdv+TuaK2w3xR9+fWNu3feMxOMZBj3P3JWXVTAv7kz5wBCSlVPa G/d7nUM6w3IXh/Xvn3FPCmt1PHd98r8p6oEvHlWtDfdlX7ivUyM5Rk7X4MQhO3MRUVtt9ron v5ZlbIww7vpfLf4hpGrbD4/vs/bP87Pv2GXmv4ZX/W//ZCWW4oxEQy3mouJEAEFtOPacAgAA X-MTR: 20000000000000000@CPGS X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20161107_020716_138679_C239A5CD X-CRM114-Status: GOOD ( 14.66 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, thomas.ab@samsung.com, Rob Herring , Pankaj Dubey , Michael Turquette , krzk@kernel.org, javier@osg.samsung.com, myungjoo.ham@samsung.com, kgene@kernel.org, linux-clk@vger.kernel.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Add Device Tree binding documentation for the clocks outputs in the Maxim-8997 Power Management IC. CC: Michael Turquette CC: Rob Herring CC: devicetree@vger.kernel.org CC: linux-clk@vger.kernel.org Signed-off-by: Pankaj Dubey Reviewed-by: Javier Martinez Canillas Acked-by: Rob Herring --- .../devicetree/bindings/clock/maxim,max8997.txt | 44 ++++++++++++++++++++++ .../bindings/regulator/max8997-regulator.txt | 3 ++ 2 files changed, 47 insertions(+) create mode 100644 Documentation/devicetree/bindings/clock/maxim,max8997.txt diff --git a/Documentation/devicetree/bindings/clock/maxim,max8997.txt b/Documentation/devicetree/bindings/clock/maxim,max8997.txt new file mode 100644 index 0000000..d2e2a74 --- /dev/null +++ b/Documentation/devicetree/bindings/clock/maxim,max8997.txt @@ -0,0 +1,44 @@ +Binding for Maxim MAX8997 32k clock generator block + +This is a part of device tree bindings of MAX8997 multi-function device. +More information can be found in bindings/regulator/max8997-regulator.txt file. + +The MAX8997 contains two 32.768khz clock outputs that can be controlled +(gated/ungated) over I2C. + +Following properties should be presend in main device node of the MFD chip. + +Required properties: + +- #clock-cells: from common clock binding; shall be set to 1. + +Optional properties: +- clock-output-names: From common clock binding. + +Each clock is assigned an identifier and client nodes can use this identifier +to specify the clock which they consume. Following indices are allowed: + - 0: 32khz_ap clock, + - 1: 32khz_cp clock, + +Clocks are defined as preprocessor macros in dt-bindings/clock/maxim,max8997.h +header and can be used in device tree sources. + +Example: Node of the MFD chip + + max8997: max8997_pmic@66 { + compatible = "maxim,max8997-pmic"; + reg = <0x66>; + interrupt-parent = <&gpx0>; + interrupts = <4 0>, <3 0>; + #clock-cells = <1>; + /* ... */ + }; + +Example: Clock consumer node + + foo@0 { + compatible = "bar,foo"; + /* ... */ + clocks = <&max8997 MAX8997_CLK_AP>; + clock-names = "my-clock"; + }; diff --git a/Documentation/devicetree/bindings/regulator/max8997-regulator.txt b/Documentation/devicetree/bindings/regulator/max8997-regulator.txt index 5c186a7..af1f9c0 100644 --- a/Documentation/devicetree/bindings/regulator/max8997-regulator.txt +++ b/Documentation/devicetree/bindings/regulator/max8997-regulator.txt @@ -6,6 +6,9 @@ interfaced to the host controller using a i2c interface. Each sub-block is addressed by the host system using different i2c slave address. This document describes the bindings for 'pmic' sub-block of max8997. +Binding for the built-in 32k clock generator block is defined separately +in bindings/clk/maxim,max8997.txt file + Required properties: - compatible: Should be "maxim,max8997-pmic". - reg: Specifies the i2c slave address of the pmic block. It should be 0x66.