cancel
Showing results for 
Search instead for 
Did you mean: 

How do I start the PER clock? U-boot won't boot

DMårt
Lead

I never heard about the PER clock. I'm looking inside CubeMX, but I don't see any PER clock at all. I guess it's periferial clock. So how do I start it?

 

My U-boot won't boot. I guess that if PER will be like 24 MHz, then U-boot will continue. Or am I wrong?

 

D/TC:0 0 call_initcalls:40 level 6 stm32mp1_init_lp_states()
D/TC:0 0 stm32mp1_init_lp_states:230 Power configuration: shutdown to 6, suspend to 2
D/TC:0 0 call_initcalls:40 level 6 regulator_core_init()
D/TC:0 0 call_initcalls:40 level 7 stm32_rng_release()
D/TC:0 0 call_initcalls:40 level 7 regulator_core_cleanup()
D/TC:0 0 regulator_core_cleanup:916 disable usb33
D/TC:0 0 regulator_core_cleanup:916 disable reg18
D/TC:0 0 regulator_core_cleanup:916 disable reg11
D/TC:0 0 call_initcalls:40 level 7 release_probe_lists()
D/TC:0 0 call_finalcalls:59 level 1 release_external_dt()
I/TC: Primary CPU switching to normal world boot
serial_stm32 serial@40010000: pinctrl_select_state_full: uclass_get_device_by_phandle_id: err=-19


U-Boot 2022.10-stm32mp-r2 (Aug 12 2024 - 23:20:26 +0200)

optee optee: OP-TEE: revision 3.19 (e413e2ec)
D/TC:0   tee_entry_exchange_capabilities:101 Asynchronous notifications are disabled
D/TC:0   tee_entry_exchange_capabilities:110 Dynamic shared memory is enabled
D/TC:0 0 core_mmu_xlat_table_alloc:526 xlat tables used 4 / 10
D/TC:? 0 tee_ta_init_pseudo_ta_session:296 Lookup pseudo TA 7011a688-ddde-4053-a5a9-7b3c4ddf13b8
D/TC:? 0 tee_ta_init_pseudo_ta_session:309 Open device.pta
D/TC:? 0 tee_ta_init_pseudo_ta_session:326 device.pta : 7011a688-ddde-4053-a5a9-7b3c4ddf13b8
D/TC:? 0 tee_ta_close_session:451 csess 0xde04a750 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_pseudo_ta_session:296 Lookup pseudo TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_init_pseudo_ta_session:309 Open bsec.pta
D/TC:? 0 tee_ta_init_pseudo_ta_session:326 bsec.pta : 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde04a648 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde04a540 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde04a540 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
CPU: STM32MP151AAC Rev.Z
Model: STMicroelectronics custom STM32CubeMX board - openstlinux-6.1-yocto-mickledore-mpu-v24.06.26
Board: stm32mp1 in trusted mode (st,stm32mp151a-stm32-computer-firmware-mx)
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde04a540 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
DRAM:  512 MiB
Clocks:
- MPU : 650 MHz
- MCU : 208.878 MHz
- AXI : 266.500 MHz
- PER : 0 MHz
- DDR : 533 MHz
optee optee: OP-TEE: revision 3.19 (e413e2ec)
D/TC:0   tee_entry_exchange_capabilities:101 Asynchronous notifications are disabled
D/TC:0   tee_entry_exchange_capabilities:110 Dynamic shared memory is enabled
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 7011a688-ddde-4053-a5a9-7b3c4ddf13b8
D/TC:? 0 tee_ta_close_session:451 csess 0xde04a540 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
STM32MP151AAC3 custom board with STM32-OS as operating system: https://github.com/DanielMartensson/STM32-Computer
1 ACCEPTED SOLUTION

Accepted Solutions

@Erwan SZYMANSKI 

Hi! It seems that I have the same clock configuration. So this means it must be a bug?

Skärmklipp.PNG

Here is my device tree for Op-tee. Do you see something suspect? ;)

 

&rcc{
	pinctrl-names = "default";
	pinctrl-0 = <&rcc_pins_mx>;
	status = "okay";

	/* USER CODE BEGIN rcc */
	/* USER CODE END rcc */

	st,clksrc=<
		CLK_CKPER_DISABLED <------------
		CLK_ETH_PLL4P
		CLK_SDMMC12_PLL4P
		CLK_STGEN_HSE
		CLK_SPI2S23_PLL3Q
		CLK_I2C46_HSI
		CLK_USBO_USBPHY
		CLK_CEC_LSE
		CLK_I2C12_HSI
		CLK_UART24_HSI

 

After fix:

By the way! CubeMX will clean the whole U-boot-mx.dts file in the device tree when I'm generating new code. It's two bugs counted now! Try it your self. Create and STM32MP151AAC3 project and write something within BEGIN and END commands of the U-boot-mx.dts file inside the DeviceTree folder. Then generate. See if it's disappear.

 

U-Boot 2022.10-stm32mp-r2 (Aug 14 2024 - 00:19:35 +0200)

D/TC:? 0 tee_ta_init_pseudo_ta_session:296 Lookup pseudo TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_init_pseudo_ta_session:309 Open bsec.pta
D/TC:? 0 tee_ta_init_pseudo_ta_session:326 bsec.pta : 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde050378 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
CPU: STM32MP151AAC Rev.Z
Model: STMicroelectronics custom STM32CubeMX board - openstlinux-6.1-yocto-mickledore-mpu-v24.06.26
Board: stm32mp1 in trusted mode (st,stm32mp151a-stm32-computer-firmware-mx)
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
DRAM:  512 MiB
optee optee: OP-TEE: revision 3.19 (c9e2d42b)
D/TC:0   tee_entry_exchange_capabilities:101 Asynchronous notifications are disabled
D/TC:0   tee_entry_exchange_capabilities:110 Dynamic shared memory is enabled
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 7011a688-ddde-4053-a5a9-7b3c4ddf13b8
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
Clocks:
- MPU : 650 MHz
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
- MCU : 208.878 MHz
- AXI : 266.500 MHz
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
- PER : 24 MHz
- DDR : 533 MHz
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1

 

STM32MP151AAC3 custom board with STM32-OS as operating system: https://github.com/DanielMartensson/STM32-Computer

View solution in original post

5 REPLIES 5
Erwan SZYMANSKI
ST Employee

Hello @DMårt ,
Yes this is peripheral clock, you can find related information in the Reference Manual (RCC chapter).

For the CubeMX configuration, you say that the PER clock is not inside, I am a bit surprised. Can you please double check, I can see this on my side (taken with the STM32MP157F-DK2 example project) :

ErwanSZYMANSKI_1-1723541621297.png

Kind regards,
Erwan.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

@Erwan SZYMANSKI 

Oh, it's called CKPER clock. Intill check. I very sure it exists for MP151.

It might be the issue, i guess.

 

I will reply later.

STM32MP151AAC3 custom board with STM32-OS as operating system: https://github.com/DanielMartensson/STM32-Computer

@Erwan SZYMANSKI 

Hi! It seems that I have the same clock configuration. So this means it must be a bug?

Skärmklipp.PNG

Here is my device tree for Op-tee. Do you see something suspect? ;)

 

&rcc{
	pinctrl-names = "default";
	pinctrl-0 = <&rcc_pins_mx>;
	status = "okay";

	/* USER CODE BEGIN rcc */
	/* USER CODE END rcc */

	st,clksrc=<
		CLK_CKPER_DISABLED <------------
		CLK_ETH_PLL4P
		CLK_SDMMC12_PLL4P
		CLK_STGEN_HSE
		CLK_SPI2S23_PLL3Q
		CLK_I2C46_HSI
		CLK_USBO_USBPHY
		CLK_CEC_LSE
		CLK_I2C12_HSI
		CLK_UART24_HSI

 

After fix:

By the way! CubeMX will clean the whole U-boot-mx.dts file in the device tree when I'm generating new code. It's two bugs counted now! Try it your self. Create and STM32MP151AAC3 project and write something within BEGIN and END commands of the U-boot-mx.dts file inside the DeviceTree folder. Then generate. See if it's disappear.

 

U-Boot 2022.10-stm32mp-r2 (Aug 14 2024 - 00:19:35 +0200)

D/TC:? 0 tee_ta_init_pseudo_ta_session:296 Lookup pseudo TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_init_pseudo_ta_session:309 Open bsec.pta
D/TC:? 0 tee_ta_init_pseudo_ta_session:326 bsec.pta : 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde050378 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
CPU: STM32MP151AAC Rev.Z
Model: STMicroelectronics custom STM32CubeMX board - openstlinux-6.1-yocto-mickledore-mpu-v24.06.26
Board: stm32mp1 in trusted mode (st,stm32mp151a-stm32-computer-firmware-mx)
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 94cf71ad-80e6-40b5-a7c6-3dc501eb2803
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
DRAM:  512 MiB
optee optee: OP-TEE: revision 3.19 (c9e2d42b)
D/TC:0   tee_entry_exchange_capabilities:101 Asynchronous notifications are disabled
D/TC:0   tee_entry_exchange_capabilities:110 Dynamic shared memory is enabled
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA 7011a688-ddde-4053-a5a9-7b3c4ddf13b8
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
Clocks:
- MPU : 650 MHz
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
- MCU : 208.878 MHz
- AXI : 266.500 MHz
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1
D/TC:? 0 tee_ta_close_session:470 Destroy session
- PER : 24 MHz
- DDR : 533 MHz
D/TC:? 0 tee_ta_init_session_with_context:549 Re-open TA a8cfe406-d4f5-4a2e-9f8d-a25dc754c099
D/TC:? 0 tee_ta_close_session:451 csess 0xde050270 id 1

 

STM32MP151AAC3 custom board with STM32-OS as operating system: https://github.com/DanielMartensson/STM32-Computer

Hello @DMårt ,
Thank you for your feedback, we will check it on our side. I hope you will be able to go forward now.

Kind regards,
Erwan.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

Hi @Erwan SZYMANSKI 

Did you know there is a STM32MP151 board that is based on STM32MP157D-DK1. It's OK if the ST dev team want to build this board and use it to debug the device tree for the 151 processor. Right now, i have seen a lot of bugs inside the device tree for the 151 processor. I guess the dev team is only using 157 and 135.

Feel free to use this. I have build a device tree for this project.

https://github.com/DanielMartensson/STM32-Computer

STM32MP151AAC3 custom board with STM32-OS as operating system: https://github.com/DanielMartensson/STM32-Computer