2023-05-20 12:39:12

by Matti Lehtimäki

[permalink] [raw]
Subject: [PATCH v2 0/4] PMU, rpm-stats and IMEM for MSM8226

This series adds PMU, rpm-stats and IMEM nodes for MSM8226.
It also defines reboot modes for MSM8226.

Changes in v2:
- Use constants instead of magic number in PMU node
- Always enable IMEM node
- Move reboot-mode magic numbers to platform,
those should be always the same, drop patch for matisse-wifi

Matti Lehtimäki (4):
dt-bindings: sram: qcom,imem: Document MSM8226
ARM: dts: qcom: msm8226: Add PMU node
ARM: dts: qcom: msm8226: Add rpm-stats device node
ARM: dts: qcom: msm8226: Add IMEM node

.../devicetree/bindings/sram/qcom,imem.yaml | 1 +
arch/arm/boot/dts/qcom-msm8226.dtsi | 25 +++++++++++++++++++
2 files changed, 26 insertions(+)

--
2.34.1



2023-05-20 12:40:31

by Matti Lehtimäki

[permalink] [raw]
Subject: [PATCH v2 1/4] dt-bindings: sram: qcom,imem: Document MSM8226

Add compatible for MSM8226 IMEM.

Signed-off-by: Matti Lehtimäki <[email protected]>
Acked-by: Conor Dooley <[email protected]>
---
Documentation/devicetree/bindings/sram/qcom,imem.yaml | 1 +
1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/sram/qcom,imem.yaml b/Documentation/devicetree/bindings/sram/qcom,imem.yaml
index ba694ce4a037..318acd129ff9 100644
--- a/Documentation/devicetree/bindings/sram/qcom,imem.yaml
+++ b/Documentation/devicetree/bindings/sram/qcom,imem.yaml
@@ -18,6 +18,7 @@ properties:
items:
- enum:
- qcom,apq8064-imem
+ - qcom,msm8226-imem
- qcom,msm8974-imem
- qcom,qcs404-imem
- qcom,sc7180-imem
--
2.34.1


2023-05-20 12:49:09

by Matti Lehtimäki

[permalink] [raw]
Subject: [PATCH v2 4/4] ARM: dts: qcom: msm8226: Add IMEM node

This enables userspace to signal the bootloader to go into the
bootloader or recovery mode.

The magic values can be found in both the downstream kernel and the LK
kernel (bootloader).

Signed-off-by: Matti Lehtimäki <[email protected]>
---
Changes in v2:
- Always enable IMEM node
- Move reboot-mode magic numbers to platform,
those should be always the same
---
arch/arm/boot/dts/qcom-msm8226.dtsi | 14 ++++++++++++++
1 file changed, 14 insertions(+)

diff --git a/arch/arm/boot/dts/qcom-msm8226.dtsi b/arch/arm/boot/dts/qcom-msm8226.dtsi
index 8644540f5aae..284b7c666fea 100644
--- a/arch/arm/boot/dts/qcom-msm8226.dtsi
+++ b/arch/arm/boot/dts/qcom-msm8226.dtsi
@@ -641,6 +641,20 @@ smd-edge {
label = "lpass";
};
};
+
+ sram@fe805000 {
+ compatible = "qcom,msm8226-imem", "syscon", "simple-mfd";
+ reg = <0xfe805000 0x1000>;
+
+ reboot-mode {
+ compatible = "syscon-reboot-mode";
+ offset = <0x65c>;
+
+ mode-bootloader = <0x77665500>;
+ mode-normal = <0x77665501>;
+ mode-recovery = <0x77665502>;
+ };
+ };
};

timer {
--
2.34.1


2023-05-22 16:21:37

by Luca Weiss

[permalink] [raw]
Subject: Re: [PATCH v2 4/4] ARM: dts: qcom: msm8226: Add IMEM node

On Samstag, 20. Mai 2023 14:19:33 CEST Matti Lehtim?ki wrote:
> This enables userspace to signal the bootloader to go into the
> bootloader or recovery mode.
>
> The magic values can be found in both the downstream kernel and the LK
> kernel (bootloader).
>
> Signed-off-by: Matti Lehtim?ki <[email protected]>

Reviewed-by: Luca Weiss <[email protected]>

> ---
> Changes in v2:
> - Always enable IMEM node
> - Move reboot-mode magic numbers to platform,
> those should be always the same
> ---
> arch/arm/boot/dts/qcom-msm8226.dtsi | 14 ++++++++++++++
> 1 file changed, 14 insertions(+)
>
> diff --git a/arch/arm/boot/dts/qcom-msm8226.dtsi
> b/arch/arm/boot/dts/qcom-msm8226.dtsi index 8644540f5aae..284b7c666fea
> 100644
> --- a/arch/arm/boot/dts/qcom-msm8226.dtsi
> +++ b/arch/arm/boot/dts/qcom-msm8226.dtsi
> @@ -641,6 +641,20 @@ smd-edge {
> label = "lpass";
> };
> };
> +
> + sram@fe805000 {
> + compatible = "qcom,msm8226-imem", "syscon",
"simple-mfd";
> + reg = <0xfe805000 0x1000>;
> +
> + reboot-mode {
> + compatible = "syscon-reboot-mode";
> + offset = <0x65c>;
> +
> + mode-bootloader = <0x77665500>;
> + mode-normal = <0x77665501>;
> + mode-recovery = <0x77665502>;
> + };
> + };
> };
>
> timer {





2023-05-25 05:44:58

by Bjorn Andersson

[permalink] [raw]
Subject: Re: (subset) [PATCH v2 0/4] PMU, rpm-stats and IMEM for MSM8226

On Sat, 20 May 2023 15:19:29 +0300, Matti Lehtimäki wrote:
> This series adds PMU, rpm-stats and IMEM nodes for MSM8226.
> It also defines reboot modes for MSM8226.
>
> Changes in v2:
> - Use constants instead of magic number in PMU node
> - Always enable IMEM node
> - Move reboot-mode magic numbers to platform,
> those should be always the same, drop patch for matisse-wifi
>
> [...]

Applied, thanks!

[2/4] ARM: dts: qcom: msm8226: Add PMU node
commit: fbc669e65fa3b4fe417c14ea194057140d7f3d74
[3/4] ARM: dts: qcom: msm8226: Add rpm-stats device node
commit: c1ba26f1a00f560f143336dc29eb6524be333a75
[4/4] ARM: dts: qcom: msm8226: Add IMEM node
commit: 94aca310e66d953c1676e71754744f181d6fe5f9

Best regards,
--
Bjorn Andersson <[email protected]>