@@ -18,6 +18,11 @@ description: |+
parental dt-node. So the SYSCON reboot node should be represented as a
sub-node of a "syscon", "simple-mfd" node. Though the regmap property
pointing to the system controller node is also supported.
+ This also supports specification of separate sets of register/mask/value
+ pairs for different types of reset: cold, hard, soft and warm, using
+ the respective properties with the respective reset type prefix. If prefixed
+ properties are not specified for a reset type, the non-prefixed properties
+ will be used for that reset type.
properties:
compatible:
@@ -49,12 +54,41 @@ properties:
priority:
default: 192
+patternProperties:
+ "^(cold|hard|soft|warm)-(mask|offset|value)$":
+ $ref: /schemas/types.yaml#/definitions/uint32
+ description:
+ Optional alternative offset / mask / value combinations for specific
+ reboot modes. The mask is optional.
+
+ "^(cold|hard|soft|warm)-reg$":
+ description:
+ Optional alternative base address and size for the reboot register for
+ specific reboot modes.
+
oneOf:
- required:
- offset
- required:
- reg
+dependencies:
+ cold-mask: [ cold-value ]
+ cold-offset: [ cold-value ]
+ cold-reg: [ cold-value ]
+
+ hard-mask: [ hard-value ]
+ hard-offset: [ hard-value ]
+ hard-reg: [ hard-value ]
+
+ soft-mask: [ soft-value ]
+ soft-offset: [ soft-value ]
+ soft-reg: [ soft-value ]
+
+ warm-mask: [ warm-value ]
+ warm-offset: [ warm-value ]
+ warm-reg: [ warm-value ]
+
required:
- compatible
@@ -70,6 +104,46 @@ allOf:
required:
- value
+ - if:
+ required:
+ - cold-value
+ then:
+ oneOf:
+ - required:
+ - cold-offset
+ - required:
+ - cold-reg
+
+ - if:
+ required:
+ - hard-value
+ then:
+ oneOf:
+ - required:
+ - hard-offset
+ - required:
+ - hard-reg
+
+ - if:
+ required:
+ - soft-value
+ then:
+ oneOf:
+ - required:
+ - soft-offset
+ - required:
+ - soft-reg
+
+ - if:
+ required:
+ - warm-value
+ then:
+ oneOf:
+ - required:
+ - warm-offset
+ - required:
+ - warm-reg
+
examples:
- |
reboot {
Add support for specifying different register/mask/value combinations for different types of reset. In particular, update the binding to allow platforms to specify the following reset modes: soft, warm, cold, hard. Linux can perform different types of reset using its reboot= kernel command line argument, and some platforms also wish to reset differently based on whether or not e.g. contents of RAM should be retained across the reboot. The new properties match the existing properties, just prefixed with one of the reset modes mentioned above. Signed-off-by: André Draszik <andre.draszik@linaro.org> --- .../bindings/power/reset/syscon-reboot.yaml | 74 ++++++++++++++++++++++ 1 file changed, 74 insertions(+)