[PATCH 1/5] ARM: dts: stm32: fullfill diversity with OPP for STM32M15x SOCs

Amelie Delaunay posted 5 patches 6 months, 3 weeks ago
There is a newer version of this series
[PATCH 1/5] ARM: dts: stm32: fullfill diversity with OPP for STM32M15x SOCs
Posted by Amelie Delaunay 6 months, 3 weeks ago
From: Alexandre Torgue <alexandre.torgue@foss.st.com>

This commit creates new files to manage security features and supported OPP
on STM32MP15x SOCs. On STM32MP15xY, "Y" gives information:
 -Y = A means no cryp IP and no secure boot + A7-CPU@650MHz.
 -Y = C means cryp IP + optee + secure boot + A7-CPU@650MHz.
 -Y = D means no cryp IP and no secure boot + A7-CPU@800MHz.
 -Y = F means cryp IP + optee + secure boot + A7-CPU@800MHz.

It fullfills the initial STM32MP15x SoC diversity introduced by
commit 0eda69b6c5f9 ("ARM: dts: stm32: Manage security diversity
for STM32M15x SOCs").

Signed-off-by: Alexandre Torgue <alexandre.torgue@foss.st.com>
Signed-off-by: Amelie Delaunay <amelie.delaunay@foss.st.com>
---
 arch/arm/boot/dts/st/stm32mp15xa.dtsi |  5 +++++
 arch/arm/boot/dts/st/stm32mp15xc.dtsi |  4 +++-
 arch/arm/boot/dts/st/stm32mp15xd.dtsi |  5 +++++
 arch/arm/boot/dts/st/stm32mp15xf.dtsi | 20 ++++++++++++++++++++
 4 files changed, 33 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/st/stm32mp15xa.dtsi b/arch/arm/boot/dts/st/stm32mp15xa.dtsi
new file mode 100644
index 0000000000000000000000000000000000000000..cb55f5966f74011d12d7a5c6ad047569d25d4e98
--- /dev/null
+++ b/arch/arm/boot/dts/st/stm32mp15xa.dtsi
@@ -0,0 +1,5 @@
+// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
+/*
+ * Copyright (C) STMicroelectronics 2025 - All Rights Reserved
+ * Author: Alexandre Torgue <alexandre.torgue@foss.st.com> for STMicroelectronics.
+ */
diff --git a/arch/arm/boot/dts/st/stm32mp15xc.dtsi b/arch/arm/boot/dts/st/stm32mp15xc.dtsi
index 97465717f932fc223647af76e88a6182cf3c870f..4d30a2a537f15c1e145635b090de0f0222526579 100644
--- a/arch/arm/boot/dts/st/stm32mp15xc.dtsi
+++ b/arch/arm/boot/dts/st/stm32mp15xc.dtsi
@@ -1,9 +1,11 @@
-// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
+// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
 /*
  * Copyright (C) STMicroelectronics 2019 - All Rights Reserved
  * Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
  */
 
+#include "stm32mp15xa.dtsi"
+
 &etzpc {
 	cryp1: cryp@54001000 {
 		compatible = "st,stm32mp1-cryp";
diff --git a/arch/arm/boot/dts/st/stm32mp15xd.dtsi b/arch/arm/boot/dts/st/stm32mp15xd.dtsi
new file mode 100644
index 0000000000000000000000000000000000000000..cb55f5966f74011d12d7a5c6ad047569d25d4e98
--- /dev/null
+++ b/arch/arm/boot/dts/st/stm32mp15xd.dtsi
@@ -0,0 +1,5 @@
+// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
+/*
+ * Copyright (C) STMicroelectronics 2025 - All Rights Reserved
+ * Author: Alexandre Torgue <alexandre.torgue@foss.st.com> for STMicroelectronics.
+ */
diff --git a/arch/arm/boot/dts/st/stm32mp15xf.dtsi b/arch/arm/boot/dts/st/stm32mp15xf.dtsi
new file mode 100644
index 0000000000000000000000000000000000000000..5f6a2952125d00d468e2e4012024f02380cfaa49
--- /dev/null
+++ b/arch/arm/boot/dts/st/stm32mp15xf.dtsi
@@ -0,0 +1,20 @@
+// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
+/*
+ * Copyright (C) STMicroelectronics 2025 - All Rights Reserved
+ * Author: Alexandre Torgue <alexandre.torgue@foss.st.com> for STMicroelectronics.
+ */
+
+#include "stm32mp15xd.dtsi"
+
+/ {
+	soc {
+		cryp1: cryp@54001000 {
+			compatible = "st,stm32mp1-cryp";
+			reg = <0x54001000 0x400>;
+			interrupts = <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;
+			clocks = <&rcc CRYP1>;
+			resets = <&rcc CRYP1_R>;
+			status = "disabled";
+		};
+	};
+};

-- 
2.25.1
Re: [PATCH 1/5] ARM: dts: stm32: fullfill diversity with OPP for STM32M15x SOCs
Posted by Krzysztof Kozlowski 6 months, 3 weeks ago
On 27/05/2025 15:03, Amelie Delaunay wrote:
> From: Alexandre Torgue <alexandre.torgue@foss.st.com>
> 
> This commit creates new files to manage security features and supported OPP
> on STM32MP15x SOCs. On STM32MP15xY, "Y" gives information:
>  -Y = A means no cryp IP and no secure boot + A7-CPU@650MHz.
>  -Y = C means cryp IP + optee + secure boot + A7-CPU@650MHz.
>  -Y = D means no cryp IP and no secure boot + A7-CPU@800MHz.
>  -Y = F means cryp IP + optee + secure boot + A7-CPU@800MHz.
> 
> It fullfills the initial STM32MP15x SoC diversity introduced by
> commit 0eda69b6c5f9 ("ARM: dts: stm32: Manage security diversity
> for STM32M15x SOCs").
> 
> Signed-off-by: Alexandre Torgue <alexandre.torgue@foss.st.com>
> Signed-off-by: Amelie Delaunay <amelie.delaunay@foss.st.com>
> ---
>  arch/arm/boot/dts/st/stm32mp15xa.dtsi |  5 +++++
>  arch/arm/boot/dts/st/stm32mp15xc.dtsi |  4 +++-
>  arch/arm/boot/dts/st/stm32mp15xd.dtsi |  5 +++++
>  arch/arm/boot/dts/st/stm32mp15xf.dtsi | 20 ++++++++++++++++++++
>  4 files changed, 33 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/arm/boot/dts/st/stm32mp15xa.dtsi b/arch/arm/boot/dts/st/stm32mp15xa.dtsi
> new file mode 100644
> index 0000000000000000000000000000000000000000..cb55f5966f74011d12d7a5c6ad047569d25d4e98
> --- /dev/null
> +++ b/arch/arm/boot/dts/st/stm32mp15xa.dtsi
> @@ -0,0 +1,5 @@
> +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
> +/*
> + * Copyright (C) STMicroelectronics 2025 - All Rights Reserved
> + * Author: Alexandre Torgue <alexandre.torgue@foss.st.com> for STMicroelectronics.

You create entirely empty, unused file. There is literally no benefit of
this file, no impact, just more files to handle.

> + */
> diff --git a/arch/arm/boot/dts/st/stm32mp15xc.dtsi b/arch/arm/boot/dts/st/stm32mp15xc.dtsi
> index 97465717f932fc223647af76e88a6182cf3c870f..4d30a2a537f15c1e145635b090de0f0222526579 100644
> --- a/arch/arm/boot/dts/st/stm32mp15xc.dtsi
> +++ b/arch/arm/boot/dts/st/stm32mp15xc.dtsi
> @@ -1,9 +1,11 @@
> -// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
> +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)

License change is not explained in commit msg and anyway should be
separate commit with acks/sobs from all copyright holders. You also need
to CC them (Cc e.g. Gatien).

>  /*
>   * Copyright (C) STMicroelectronics 2019 - All Rights Reserved
>   * Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
>   */
>  
> +#include "stm32mp15xa.dtsi"
> +
>  &etzpc {
>  	cryp1: cryp@54001000 {
>  		compatible = "st,stm32mp1-cryp";
> diff --git a/arch/arm/boot/dts/st/stm32mp15xd.dtsi b/arch/arm/boot/dts/st/stm32mp15xd.dtsi
> new file mode 100644
> index 0000000000000000000000000000000000000000..cb55f5966f74011d12d7a5c6ad047569d25d4e98
> --- /dev/null
> +++ b/arch/arm/boot/dts/st/stm32mp15xd.dtsi
> @@ -0,0 +1,5 @@
> +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
> +/*
> + * Copyright (C) STMicroelectronics 2025 - All Rights Reserved
> + * Author: Alexandre Torgue <alexandre.torgue@foss.st.com> for STMicroelectronics.
> + */

Same problems.

> diff --git a/arch/arm/boot/dts/st/stm32mp15xf.dtsi b/arch/arm/boot/dts/st/stm32mp15xf.dtsi
> new file mode 100644
> index 0000000000000000000000000000000000000000..5f6a2952125d00d468e2e4012024f02380cfaa49
> --- /dev/null
> +++ b/arch/arm/boot/dts/st/stm32mp15xf.dtsi
> @@ -0,0 +1,20 @@
> +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
> +/*
> + * Copyright (C) STMicroelectronics 2025 - All Rights Reserved
> + * Author: Alexandre Torgue <alexandre.torgue@foss.st.com> for STMicroelectronics.
> + */
> +
> +#include "stm32mp15xd.dtsi"
> +
> +/ {
> +	soc {
> +		cryp1: cryp@54001000 {
> +			compatible = "st,stm32mp1-cryp";
> +			reg = <0x54001000 0x400>;
> +			interrupts = <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;
> +			clocks = <&rcc CRYP1>;
> +			resets = <&rcc CRYP1_R>;
> +			status = "disabled";
> +		};
> +	};
> +};
> 


Best regards,
Krzysztof
Re: [PATCH 1/5] ARM: dts: stm32: fullfill diversity with OPP for STM32M15x SOCs
Posted by Amelie Delaunay 6 months, 3 weeks ago

On 5/27/25 15:12, Krzysztof Kozlowski wrote:
> On 27/05/2025 15:03, Amelie Delaunay wrote:
>> From: Alexandre Torgue <alexandre.torgue@foss.st.com>
>>
>> This commit creates new files to manage security features and supported OPP
>> on STM32MP15x SOCs. On STM32MP15xY, "Y" gives information:
>>   -Y = A means no cryp IP and no secure boot + A7-CPU@650MHz.
>>   -Y = C means cryp IP + optee + secure boot + A7-CPU@650MHz.
>>   -Y = D means no cryp IP and no secure boot + A7-CPU@800MHz.
>>   -Y = F means cryp IP + optee + secure boot + A7-CPU@800MHz.
>>
>> It fullfills the initial STM32MP15x SoC diversity introduced by
>> commit 0eda69b6c5f9 ("ARM: dts: stm32: Manage security diversity
>> for STM32M15x SOCs").
>>
>> Signed-off-by: Alexandre Torgue <alexandre.torgue@foss.st.com>
>> Signed-off-by: Amelie Delaunay <amelie.delaunay@foss.st.com>
>> ---
>>   arch/arm/boot/dts/st/stm32mp15xa.dtsi |  5 +++++
>>   arch/arm/boot/dts/st/stm32mp15xc.dtsi |  4 +++-
>>   arch/arm/boot/dts/st/stm32mp15xd.dtsi |  5 +++++
>>   arch/arm/boot/dts/st/stm32mp15xf.dtsi | 20 ++++++++++++++++++++
>>   4 files changed, 33 insertions(+), 1 deletion(-)
>>
>> diff --git a/arch/arm/boot/dts/st/stm32mp15xa.dtsi b/arch/arm/boot/dts/st/stm32mp15xa.dtsi
>> new file mode 100644
>> index 0000000000000000000000000000000000000000..cb55f5966f74011d12d7a5c6ad047569d25d4e98
>> --- /dev/null
>> +++ b/arch/arm/boot/dts/st/stm32mp15xa.dtsi
>> @@ -0,0 +1,5 @@
>> +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
>> +/*
>> + * Copyright (C) STMicroelectronics 2025 - All Rights Reserved
>> + * Author: Alexandre Torgue <alexandre.torgue@foss.st.com> for STMicroelectronics.
> 
> You create entirely empty, unused file. There is literally no benefit of
> this file, no impact, just more files to handle.
> 

Indeed, this one is not useful and will be dropped in v2, as it won't be 
populated with cpufreq/thermal updates due to fixed cpu clock frequency.

>> + */
>> diff --git a/arch/arm/boot/dts/st/stm32mp15xc.dtsi b/arch/arm/boot/dts/st/stm32mp15xc.dtsi
>> index 97465717f932fc223647af76e88a6182cf3c870f..4d30a2a537f15c1e145635b090de0f0222526579 100644
>> --- a/arch/arm/boot/dts/st/stm32mp15xc.dtsi
>> +++ b/arch/arm/boot/dts/st/stm32mp15xc.dtsi
>> @@ -1,9 +1,11 @@
>> -// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
>> +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
> 
> License change is not explained in commit msg and anyway should be
> separate commit with acks/sobs from all copyright holders. You also need
> to CC them (Cc e.g. Gatien).
> 

License change is not needed, good to know how it should have been done. 
Since stm32mp15xa.dtsi will be dropped in v2, this file won't be updated 
and the license won't change.

>>   /*
>>    * Copyright (C) STMicroelectronics 2019 - All Rights Reserved
>>    * Author: Alexandre Torgue <alexandre.torgue@st.com> for STMicroelectronics.
>>    */
>>   
>> +#include "stm32mp15xa.dtsi"
>> +
>>   &etzpc {
>>   	cryp1: cryp@54001000 {
>>   		compatible = "st,stm32mp1-cryp";
>> diff --git a/arch/arm/boot/dts/st/stm32mp15xd.dtsi b/arch/arm/boot/dts/st/stm32mp15xd.dtsi
>> new file mode 100644
>> index 0000000000000000000000000000000000000000..cb55f5966f74011d12d7a5c6ad047569d25d4e98
>> --- /dev/null
>> +++ b/arch/arm/boot/dts/st/stm32mp15xd.dtsi
>> @@ -0,0 +1,5 @@
>> +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
>> +/*
>> + * Copyright (C) STMicroelectronics 2025 - All Rights Reserved
>> + * Author: Alexandre Torgue <alexandre.torgue@foss.st.com> for STMicroelectronics.
>> + */
> 
> Same problems.
> 

This file won't be empty, it will be populated with cpufreq/thermal 
updates because STM32MP15xD and STM32MP15xF have dynamic CPU frequency 
scaling.

>> diff --git a/arch/arm/boot/dts/st/stm32mp15xf.dtsi b/arch/arm/boot/dts/st/stm32mp15xf.dtsi
>> new file mode 100644
>> index 0000000000000000000000000000000000000000..5f6a2952125d00d468e2e4012024f02380cfaa49
>> --- /dev/null
>> +++ b/arch/arm/boot/dts/st/stm32mp15xf.dtsi
>> @@ -0,0 +1,20 @@
>> +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
>> +/*
>> + * Copyright (C) STMicroelectronics 2025 - All Rights Reserved
>> + * Author: Alexandre Torgue <alexandre.torgue@foss.st.com> for STMicroelectronics.
>> + */
>> +
>> +#include "stm32mp15xd.dtsi"
>> +
>> +/ {
>> +	soc {
>> +		cryp1: cryp@54001000 {
>> +			compatible = "st,stm32mp1-cryp";
>> +			reg = <0x54001000 0x400>;
>> +			interrupts = <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;
>> +			clocks = <&rcc CRYP1>;
>> +			resets = <&rcc CRYP1_R>;
>> +			status = "disabled";
>> +		};
>> +	};
>> +};
>>
> 
> 
> Best regards,
> Krzysztof

Regards,
Amelie
Re: [PATCH 1/5] ARM: dts: stm32: fullfill diversity with OPP for STM32M15x SOCs
Posted by Krzysztof Kozlowski 6 months, 3 weeks ago
On 27/05/2025 16:03, Amelie Delaunay wrote:
>>>   	cryp1: cryp@54001000 {
>>>   		compatible = "st,stm32mp1-cryp";
>>> diff --git a/arch/arm/boot/dts/st/stm32mp15xd.dtsi b/arch/arm/boot/dts/st/stm32mp15xd.dtsi
>>> new file mode 100644
>>> index 0000000000000000000000000000000000000000..cb55f5966f74011d12d7a5c6ad047569d25d4e98
>>> --- /dev/null
>>> +++ b/arch/arm/boot/dts/st/stm32mp15xd.dtsi
>>> @@ -0,0 +1,5 @@
>>> +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause)
>>> +/*
>>> + * Copyright (C) STMicroelectronics 2025 - All Rights Reserved
>>> + * Author: Alexandre Torgue <alexandre.torgue@foss.st.com> for STMicroelectronics.
>>> + */
>>
>> Same problems.
>>
> 
> This file won't be empty, it will be populated with cpufreq/thermal 
> updates because STM32MP15xD and STM32MP15xF have dynamic CPU frequency 
> scaling.
> 
The problem is that file now is empty, so it brings no benefits. Just
add the file when you have any content for it.

Best regards,
Krzysztof