Message ID | 20250408-wdt_reset_reason-v1-4-e6ec30c2c926@oss.qualcomm.com |
---|---|
State | New |
Headers | show |
Series | Add support to read the restart reason from IMEM | expand |
On 08/04/2025 10:49, Kathiravan Thirumoorthy wrote: > In the Qualcomm IPQ SoCs, system restart reason is captured in the IMEM > location by bootloaders and Linux populates this information to the > userspace. Add a child node for the restart reason in the IMEM region. > > Signed-off-by: Kathiravan Thirumoorthy <kathiravan.thirumoorthy@oss.qualcomm.com> > --- > .../devicetree/bindings/sram/qcom,imem.yaml | 24 ++++++++++++++++++++++ > 1 file changed, 24 insertions(+) > > diff --git a/Documentation/devicetree/bindings/sram/qcom,imem.yaml b/Documentation/devicetree/bindings/sram/qcom,imem.yaml > index dec1b1ee924cf1386f559eb262ea864f2788c165..c3dab5fbc88c1515bfb3585f18aed9e01ae36fe4 100644 > --- a/Documentation/devicetree/bindings/sram/qcom,imem.yaml > +++ b/Documentation/devicetree/bindings/sram/qcom,imem.yaml > @@ -56,6 +56,10 @@ patternProperties: > $ref: /schemas/remoteproc/qcom,pil-info.yaml# > description: Peripheral image loader relocation region > > + "^restart-reason@[0-9a-f]+$": > + $ref: /schemas/watchdog/qcom,restart-reason.yaml# Just fold it here... but really, there is little point in describing memory layout of syscon block register by register. What will be next? Another entry for one more register? And then another? And another? And every time you will claim "just this one", because you decide not to provide complete picture when sending bindings for the first time? Best regards, Krzysztof
diff --git a/Documentation/devicetree/bindings/sram/qcom,imem.yaml b/Documentation/devicetree/bindings/sram/qcom,imem.yaml index dec1b1ee924cf1386f559eb262ea864f2788c165..c3dab5fbc88c1515bfb3585f18aed9e01ae36fe4 100644 --- a/Documentation/devicetree/bindings/sram/qcom,imem.yaml +++ b/Documentation/devicetree/bindings/sram/qcom,imem.yaml @@ -56,6 +56,10 @@ patternProperties: $ref: /schemas/remoteproc/qcom,pil-info.yaml# description: Peripheral image loader relocation region + "^restart-reason@[0-9a-f]+$": + $ref: /schemas/watchdog/qcom,restart-reason.yaml# + description: IPQ SoC restart reason region + required: - compatible - reg @@ -82,3 +86,23 @@ examples: }; }; }; + + - | + soc { + #address-cells = <2>; + #size-cells = <2>; + + sram@8600000 { + compatible = "qcom,ipq5424-imem", "syscon", "simple-mfd"; + reg = <0 0x08600000 0 0x1000>; + ranges = <0 0 0x08600000 0x1000>; + + #address-cells = <1>; + #size-cells = <1>; + + restart-reason@7b0 { + compatible = "qcom,restart-reason-info"; + reg = <0x7b0 0x4>; + }; + }; + };
In the Qualcomm IPQ SoCs, system restart reason is captured in the IMEM location by bootloaders and Linux populates this information to the userspace. Add a child node for the restart reason in the IMEM region. Signed-off-by: Kathiravan Thirumoorthy <kathiravan.thirumoorthy@oss.qualcomm.com> --- .../devicetree/bindings/sram/qcom,imem.yaml | 24 ++++++++++++++++++++++ 1 file changed, 24 insertions(+)