dt-bindings: Add qcom spmi_pmic clock divider bindings
authorTirupathi Reddy <tirupath@codeaurora.org>
Tue, 21 Nov 2017 09:11:05 +0000 (14:41 +0530)
committerStephen Boyd <sboyd@codeaurora.org>
Thu, 7 Dec 2017 06:29:48 +0000 (22:29 -0800)
This patch adds device tree bindings for Qualcomm SPMI PMIC
clock divider module.

Signed-off-by: Tirupathi Reddy <tirupath@codeaurora.org>
[sboyd: Moved file to match compatible of binding]
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Documentation/devicetree/bindings/clock/qcom,spmi-clkdiv.txt [new file with mode: 0644]

diff --git a/Documentation/devicetree/bindings/clock/qcom,spmi-clkdiv.txt b/Documentation/devicetree/bindings/clock/qcom,spmi-clkdiv.txt
new file mode 100644 (file)
index 0000000..7474aba
--- /dev/null
@@ -0,0 +1,59 @@
+Qualcomm Technologies, Inc. SPMI PMIC clock divider (clkdiv)
+
+clkdiv configures the clock frequency of a set of outputs on the PMIC.
+These clocks are typically wired through alternate functions on
+gpio pins.
+
+=======================
+Properties
+=======================
+
+- compatible
+       Usage:      required
+       Value type: <string>
+       Definition: must be "qcom,spmi-clkdiv".
+
+- reg
+       Usage:      required
+       Value type: <prop-encoded-array>
+       Definition: base address of CLKDIV peripherals.
+
+- qcom,num-clkdivs
+       Usage:      required
+       Value type: <u32>
+       Definition: number of CLKDIV peripherals.
+
+- clocks:
+       Usage: required
+       Value type: <prop-encoded-array>
+       Definition: reference to the xo clock.
+
+- clock-names:
+       Usage: required
+       Value type: <stringlist>
+       Definition: must be "xo".
+
+- #clock-cells:
+       Usage: required
+       Value type: <u32>
+       Definition: shall contain 1.
+
+=======
+Example
+=======
+
+pm8998_clk_divs: clock-controller@5b00 {
+       compatible = "qcom,spmi-clkdiv";
+       reg = <0x5b00>;
+       #clock-cells = <1>;
+       qcom,num-clkdivs = <3>;
+       clocks = <&xo_board>;
+       clock-names = "xo";
+
+       assigned-clocks = <&pm8998_clk_divs 1>,
+                         <&pm8998_clk_divs 2>,
+                         <&pm8998_clk_divs 3>;
+       assigned-clock-rates = <9600000>,
+                              <9600000>,
+                              <9600000>;
+};