Tomasz Figa | aa42240 | 2014-09-19 20:27:36 +0200 | [diff] [blame] | 1 | * Generic PM domains |
| 2 | |
| 3 | System on chip designs are often divided into multiple PM domains that can be |
| 4 | used for power gating of selected IP blocks for power saving by reduced leakage |
| 5 | current. |
| 6 | |
| 7 | This device tree binding can be used to bind PM domain consumer devices with |
| 8 | their PM domains provided by PM domain providers. A PM domain provider can be |
| 9 | represented by any node in the device tree and can provide one or more PM |
| 10 | domains. A consumer node can refer to the provider by a phandle and a set of |
| 11 | phandle arguments (so called PM domain specifiers) of length specified by the |
| 12 | #power-domain-cells property in the PM domain provider node. |
| 13 | |
| 14 | ==PM domain providers== |
| 15 | |
| 16 | Required properties: |
| 17 | - #power-domain-cells : Number of cells in a PM domain specifier; |
| 18 | Typically 0 for nodes representing a single PM domain and 1 for nodes |
| 19 | providing multiple PM domains (e.g. power controllers), but can be any value |
| 20 | as specified by device tree binding documentation of particular provider. |
| 21 | |
Marek Szyprowski | dbe6754 | 2015-02-04 23:44:15 +0900 | [diff] [blame] | 22 | Optional properties: |
| 23 | - power-domains : A phandle and PM domain specifier as defined by bindings of |
| 24 | the power controller specified by phandle. |
| 25 | Some power domains might be powered from another power domain (or have |
| 26 | other hardware specific dependencies). For representing such dependency |
| 27 | a standard PM domain consumer binding is used. When provided, all domains |
| 28 | created by the given provider should be subdomains of the domain |
| 29 | specified by this binding. More details about power domain specifier are |
| 30 | available in the next section. |
| 31 | |
Tomasz Figa | aa42240 | 2014-09-19 20:27:36 +0200 | [diff] [blame] | 32 | Example: |
| 33 | |
| 34 | power: power-controller@12340000 { |
| 35 | compatible = "foo,power-controller"; |
| 36 | reg = <0x12340000 0x1000>; |
| 37 | #power-domain-cells = <1>; |
| 38 | }; |
| 39 | |
| 40 | The node above defines a power controller that is a PM domain provider and |
| 41 | expects one cell as its phandle argument. |
| 42 | |
Marek Szyprowski | dbe6754 | 2015-02-04 23:44:15 +0900 | [diff] [blame] | 43 | Example 2: |
| 44 | |
| 45 | parent: power-controller@12340000 { |
| 46 | compatible = "foo,power-controller"; |
| 47 | reg = <0x12340000 0x1000>; |
| 48 | #power-domain-cells = <1>; |
| 49 | }; |
| 50 | |
| 51 | child: power-controller@12340000 { |
| 52 | compatible = "foo,power-controller"; |
| 53 | reg = <0x12341000 0x1000>; |
| 54 | power-domains = <&parent 0>; |
| 55 | #power-domain-cells = <1>; |
| 56 | }; |
| 57 | |
| 58 | The nodes above define two power controllers: 'parent' and 'child'. |
| 59 | Domains created by the 'child' power controller are subdomains of '0' power |
| 60 | domain provided by the 'parent' power controller. |
| 61 | |
Tomasz Figa | aa42240 | 2014-09-19 20:27:36 +0200 | [diff] [blame] | 62 | ==PM domain consumers== |
| 63 | |
| 64 | Required properties: |
| 65 | - power-domains : A phandle and PM domain specifier as defined by bindings of |
| 66 | the power controller specified by phandle. |
| 67 | |
| 68 | Example: |
| 69 | |
| 70 | leaky-device@12350000 { |
| 71 | compatible = "foo,i-leak-current"; |
| 72 | reg = <0x12350000 0x1000>; |
| 73 | power-domains = <&power 0>; |
| 74 | }; |
| 75 | |
| 76 | The node above defines a typical PM domain consumer device, which is located |
| 77 | inside a PM domain with index 0 of a power controller represented by a node |
| 78 | with the label "power". |