Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: sram: convert rockchip-pmu-sram bindings to yaml

Current dts files with 'rockchip-pmu-sram' compatible nodes
are now verified with sram.yaml, although the original
text document still exists. Merge rockchip-pmu-sram.txt
with sram.yaml by adding it as description with an example.
Make #address-cells, #size-cells and ranges optional
if there are no child nodes to prevent yaml warnings.

Signed-off-by: Johan Jonker <jbx6244@gmail.com>
Signed-off-by: Rob Herring <robh@kernel.org>

authored by

Johan Jonker and committed by
Rob Herring
2d4a22e7 8d3cdfec

+23 -19
-16
Documentation/devicetree/bindings/sram/rockchip-pmu-sram.txt
··· 1 - Rockchip SRAM for pmu: 2 - ------------------------------ 3 - 4 - The sram of pmu is used to store the function of resume from maskrom(the 1st 5 - level loader). This is a common use of the "pmu-sram" because it keeps power 6 - even in low power states in the system. 7 - 8 - Required node properties: 9 - - compatible : should be "rockchip,rk3288-pmu-sram" 10 - - reg : physical base address and the size of the registers window 11 - 12 - Example: 13 - sram@ff720000 { 14 - compatible = "rockchip,rk3288-pmu-sram", "mmio-sram"; 15 - reg = <0xff720000 0x1000>; 16 - };
+23 -3
Documentation/devicetree/bindings/sram/sram.yaml
··· 29 29 enum: 30 30 - mmio-sram 31 31 - atmel,sama5d2-securam 32 + - rockchip,rk3288-pmu-sram 32 33 33 34 reg: 34 35 maxItems: 1 ··· 121 120 required: 122 121 - compatible 123 122 - reg 124 - - "#address-cells" 125 - - "#size-cells" 126 - - ranges 123 + 124 + if: 125 + properties: 126 + compatible: 127 + contains: 128 + const: rockchip,rk3288-pmu-sram 129 + 130 + else: 131 + required: 132 + - "#address-cells" 133 + - "#size-cells" 134 + - ranges 127 135 128 136 additionalProperties: false 129 137 ··· 233 223 compatible = "rockchip,rk3066-smp-sram"; 234 224 reg = <0x10080000 0x50>; 235 225 }; 226 + }; 227 + 228 + - | 229 + // Rockchip's rk3288 SoC uses the sram of pmu to store the function of 230 + // resume from maskrom(the 1st level loader). This is a common use of 231 + // the "pmu-sram" because it keeps power even in low power states 232 + // in the system. 233 + sram@ff720000 { 234 + compatible = "rockchip,rk3288-pmu-sram", "mmio-sram"; 235 + reg = <0xff720000 0x1000>; 236 236 }; 237 237 238 238 - |