Yadwinder Singh Brar | aa32aca | 2013-06-29 18:21:20 +0530 | [diff] [blame] | 1 | |
| 2 | * Samsung S2MPS11 Voltage and Current Regulator |
| 3 | |
Sachin Kamat | 9a46847 | 2013-11-08 17:05:42 +0530 | [diff] [blame] | 4 | The Samsung S2MPS11 is a multi-function device which includes voltage and |
Yadwinder Singh Brar | aa32aca | 2013-06-29 18:21:20 +0530 | [diff] [blame] | 5 | current regulators, RTC, charger controller and other sub-blocks. It is |
Sachin Kamat | 9a46847 | 2013-11-08 17:05:42 +0530 | [diff] [blame] | 6 | interfaced to the host controller using an I2C interface. Each sub-block is |
| 7 | addressed by the host system using different I2C slave addresses. |
Yadwinder Singh Brar | aa32aca | 2013-06-29 18:21:20 +0530 | [diff] [blame] | 8 | |
| 9 | Required properties: |
| 10 | - compatible: Should be "samsung,s2mps11-pmic". |
| 11 | - reg: Specifies the I2C slave address of the pmic block. It should be 0x66. |
| 12 | |
| 13 | Optional properties: |
| 14 | - interrupt-parent: Specifies the phandle of the interrupt controller to which |
| 15 | the interrupts from s2mps11 are delivered to. |
| 16 | - interrupts: Interrupt specifiers for interrupt sources. |
| 17 | |
| 18 | Optional nodes: |
Yadwinder Singh Brar | 3134bca | 2013-07-07 17:14:21 +0530 | [diff] [blame] | 19 | - clocks: s2mps11 provides three(AP/CP/BT) buffered 32.768 KHz outputs, so to |
| 20 | register these as clocks with common clock framework instantiate a sub-node |
| 21 | named "clocks". It uses the common clock binding documented in : |
| 22 | [Documentation/devicetree/bindings/clock/clock-bindings.txt] |
| 23 | - #clock-cells: should be 1. |
| 24 | |
| 25 | - The following is the list of clocks generated by the controller. Each clock |
| 26 | is assigned an identifier and client nodes use this identifier to specify |
| 27 | the clock which they consume. |
| 28 | Clock ID |
| 29 | ---------------------- |
| 30 | 32KhzAP 0 |
| 31 | 32KhzCP 1 |
| 32 | 32KhzBT 2 |
| 33 | |
Yadwinder Singh Brar | aa32aca | 2013-06-29 18:21:20 +0530 | [diff] [blame] | 34 | - regulators: The regulators of s2mps11 that have to be instantiated should be |
| 35 | included in a sub-node named 'regulators'. Regulator nodes included in this |
| 36 | sub-node should be of the format as listed below. |
| 37 | |
| 38 | regulator_name { |
| 39 | [standard regulator constraints....]; |
| 40 | }; |
| 41 | |
| 42 | regulator-ramp-delay for BUCKs = [6250/12500/25000(default)/50000] uV/us |
| 43 | |
| 44 | BUCK[2/3/4/6] supports disabling ramp delay on hardware, so explictly |
| 45 | regulator-ramp-delay = <0> can be used for them to disable ramp delay. |
Sachin Kamat | 9a46847 | 2013-11-08 17:05:42 +0530 | [diff] [blame] | 46 | In the absence of the regulator-ramp-delay property, the default ramp |
| 47 | delay will be used. |
Yadwinder Singh Brar | aa32aca | 2013-06-29 18:21:20 +0530 | [diff] [blame] | 48 | |
| 49 | NOTE: Some BUCKs share the ramp rate setting i.e. same ramp value will be set |
| 50 | for a particular group of BUCKs. So provide same regulator-ramp-delay<value>. |
| 51 | Grouping of BUCKs sharing ramp rate setting is as follow : BUCK[1, 6], |
| 52 | BUCK[3, 4], and BUCK[7, 8, 10] |
| 53 | |
| 54 | The regulator constraints inside the regulator nodes use the standard regulator |
| 55 | bindings which are documented elsewhere. |
| 56 | |
| 57 | The following are the names of the regulators that the s2mps11 pmic block |
| 58 | supports. Note: The 'n' in LDOn and BUCKn represents the LDO or BUCK number |
| 59 | as per the datasheet of s2mps11. |
| 60 | |
| 61 | - LDOn |
Sachin Kamat | 9a46847 | 2013-11-08 17:05:42 +0530 | [diff] [blame] | 62 | - valid values for n are 1 to 38 |
Sachin Kamat | 94100e7 | 2013-12-24 14:53:25 +0530 | [diff] [blame^] | 63 | - Example: LDO1, LD02, LDO28 |
Yadwinder Singh Brar | aa32aca | 2013-06-29 18:21:20 +0530 | [diff] [blame] | 64 | - BUCKn |
Sachin Kamat | 9a46847 | 2013-11-08 17:05:42 +0530 | [diff] [blame] | 65 | - valid values for n are 1 to 10. |
Yadwinder Singh Brar | aa32aca | 2013-06-29 18:21:20 +0530 | [diff] [blame] | 66 | - Example: BUCK1, BUCK2, BUCK9 |
| 67 | |
| 68 | Example: |
| 69 | |
| 70 | s2mps11_pmic@66 { |
| 71 | compatible = "samsung,s2mps11-pmic"; |
| 72 | reg = <0x66>; |
| 73 | |
Yadwinder Singh Brar | 3134bca | 2013-07-07 17:14:21 +0530 | [diff] [blame] | 74 | s2m_osc: clocks{ |
| 75 | #clock-cells = 1; |
| 76 | clock-output-names = "xx", "yy", "zz"; |
| 77 | }; |
| 78 | |
Yadwinder Singh Brar | aa32aca | 2013-06-29 18:21:20 +0530 | [diff] [blame] | 79 | regulators { |
| 80 | ldo1_reg: LDO1 { |
| 81 | regulator-name = "VDD_ABB_3.3V"; |
| 82 | regulator-min-microvolt = <3300000>; |
| 83 | regulator-max-microvolt = <3300000>; |
| 84 | }; |
| 85 | |
| 86 | ldo2_reg: LDO2 { |
| 87 | regulator-name = "VDD_ALIVE_1.1V"; |
| 88 | regulator-min-microvolt = <1100000>; |
| 89 | regulator-max-microvolt = <1100000>; |
| 90 | regulator-always-on; |
| 91 | }; |
| 92 | |
| 93 | buck1_reg: BUCK1 { |
| 94 | regulator-name = "vdd_mif"; |
| 95 | regulator-min-microvolt = <950000>; |
| 96 | regulator-max-microvolt = <1350000>; |
| 97 | regulator-always-on; |
| 98 | regulator-boot-on; |
| 99 | }; |
| 100 | |
| 101 | buck2_reg: BUCK2 { |
| 102 | regulator-name = "vdd_arm"; |
| 103 | regulator-min-microvolt = <950000>; |
| 104 | regulator-max-microvolt = <1350000>; |
| 105 | regulator-always-on; |
| 106 | regulator-boot-on; |
| 107 | regulator-ramp-delay = <50000>; |
| 108 | }; |
| 109 | }; |
| 110 | }; |