Skip to content

Commit 18dfc0b

Browse files
xdarklightkhilman
authored andcommitted
dt-bindings: power: meson-ee-pwrc: add support for Meson8/8b/8m2
The power domains on the 32-bit Meson8/Meson8b/Meson8m2 SoCs are very similar to what G12A still uses. The (known) differences are: - Meson8 doesn't use any reset lines at all - Meson8b and Meson8m2 use the same reset lines, which are different from what the 64-bit SoCs use - there is no "vapb" clock on the older SoCs - amlogic,ao-sysctrl cannot point to the whole AO sysctrl region but only the power management related registers Add a new compatible string and adjust clock and reset line expectations for each SoC. Signed-off-by: Martin Blumenstingl <[email protected]> Signed-off-by: Kevin Hilman <[email protected]> Reviewed-by: Rob Herring <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent 8f3d9f3 commit 18dfc0b

File tree

2 files changed

+72
-15
lines changed

2 files changed

+72
-15
lines changed

Documentation/devicetree/bindings/power/amlogic,meson-ee-pwrc.yaml

Lines changed: 59 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,19 @@ description: |+
2323
properties:
2424
compatible:
2525
enum:
26+
- amlogic,meson8-pwrc
27+
- amlogic,meson8b-pwrc
28+
- amlogic,meson8m2-pwrc
2629
- amlogic,meson-g12a-pwrc
2730
- amlogic,meson-sm1-pwrc
2831

2932
clocks:
30-
minItems: 2
33+
minItems: 1
34+
maxItems: 2
3135

3236
clock-names:
37+
minItems: 1
38+
maxItems: 2
3339
items:
3440
- const: vpu
3541
- const: vapb
@@ -38,18 +44,7 @@ properties:
3844
minItems: 11
3945

4046
reset-names:
41-
items:
42-
- const: viu
43-
- const: venc
44-
- const: vcbus
45-
- const: bt656
46-
- const: rdma
47-
- const: venci
48-
- const: vencp
49-
- const: vdac
50-
- const: vdi6
51-
- const: vencl
52-
- const: vid_lock
47+
minItems: 11
5348

5449
"#power-domain-cells":
5550
const: 1
@@ -59,12 +54,61 @@ properties:
5954
allOf:
6055
- $ref: /schemas/types.yaml#/definitions/phandle
6156

57+
allOf:
58+
- if:
59+
properties:
60+
compatible:
61+
enum:
62+
- amlogic,meson8b-pwrc
63+
- amlogic,meson8m2-pwrc
64+
then:
65+
properties:
66+
reset-names:
67+
items:
68+
- const: dblk
69+
- const: pic_dc
70+
- const: hdmi_apb
71+
- const: hdmi_system
72+
- const: venci
73+
- const: vencp
74+
- const: vdac
75+
- const: vencl
76+
- const: viu
77+
- const: venc
78+
- const: rdma
79+
required:
80+
- resets
81+
- reset-names
82+
83+
- if:
84+
properties:
85+
compatible:
86+
enum:
87+
- amlogic,meson-g12a-pwrc
88+
- amlogic,meson-sm1-pwrc
89+
then:
90+
properties:
91+
reset-names:
92+
items:
93+
- const: viu
94+
- const: venc
95+
- const: vcbus
96+
- const: bt656
97+
- const: rdma
98+
- const: venci
99+
- const: vencp
100+
- const: vdac
101+
- const: vdi6
102+
- const: vencl
103+
- const: vid_lock
104+
required:
105+
- resets
106+
- reset-names
107+
62108
required:
63109
- compatible
64110
- clocks
65111
- clock-names
66-
- resets
67-
- reset-names
68112
- "#power-domain-cells"
69113
- amlogic,ao-sysctrl
70114

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
/* SPDX-License-Identifier: (GPL-2.0+ or MIT) */
2+
/*
3+
* Copyright (c) 2019 Martin Blumenstingl <[email protected]>
4+
*/
5+
6+
#ifndef _DT_BINDINGS_MESON8_POWER_H
7+
#define _DT_BINDINGS_MESON8_POWER_H
8+
9+
#define PWRC_MESON8_VPU_ID 0
10+
#define PWRC_MESON8_ETHERNET_MEM_ID 1
11+
#define PWRC_MESON8_AUDIO_DSP_MEM_ID 2
12+
13+
#endif /* _DT_BINDINGS_MESON8_POWER_H */

0 commit comments

Comments
 (0)