diff --git a/bindings/power/reset/qcom,reboot-reason.yaml b/bindings/power/reset/qcom,reboot-reason.yaml new file mode 100644 index 00000000..1f871355 --- /dev/null +++ b/bindings/power/reset/qcom,reboot-reason.yaml @@ -0,0 +1,45 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: "http://devicetree.org/schemas/power/reset/qcom-reboot-reason.yaml#" +$schema: "http://devicetree.org/meta-schemas/core.yaml#" + +title: Qualcomm Technologies, Inc. Reboot Reason + +maintainers: + - Elliot Berman + +description: | + Qualcomm Technologies, Inc. SoCs support booting to special download + modes after a restart. These modes could be a :wnormal restart, + restarting into a ramdump collection mode (CrashDump), or restarting + into "emergency download mode". + +properties: + compatible: + items: + - const: qcom,reboot-mode + + allOf: + - $ref: /schemas/nvmem/nvmem-consumer.yaml#/properties + - items: + nvmem-cell-names: + items: + - const: restart_reason + +required: + - compatible + - nvmem-cells-names + +dependencies: + allOf: + - $ref: /schemas/nvmem/nvmem-consumer.yaml#/dependencies + + +examples: + - | + reboot-reason { + compatible = "qcom,reboot-reason"; + nvmem-cells = <&restart_reason>; + nvmem-cell-names = "restart_reason"; + }; diff --git a/qcom/sun-pmic-overlay.dtsi b/qcom/sun-pmic-overlay.dtsi index b736c4ee..e27955b6 100644 --- a/qcom/sun-pmic-overlay.dtsi +++ b/qcom/sun-pmic-overlay.dtsi @@ -88,6 +88,12 @@ }; &soc { + reboot_reason { + compatible = "qcom,reboot-reason"; + nvmem-cells = <&restart_reason>; + nvmem-cell-names = "restart_reason"; + }; + pmic-pon-log { compatible = "qcom,pmic-pon-log"; nvmem = <&pmk8550_sdam_5>, <&pmk8550_sdam_6>; diff --git a/qcom/sun.dtsi b/qcom/sun.dtsi index 75e6fadd..c5ef12eb 100644 --- a/qcom/sun.dtsi +++ b/qcom/sun.dtsi @@ -293,6 +293,7 @@ &firmware { qcom-scm { compatible = "qcom,scm"; + qcom,dload-mode = <&tcsr 0x19000>; }; qcom_smcinvoke {