There is a requirement is that keep an IO high level when APP jump to the bootloader, so it is not feasibile to enter Bootloader by software reset.
It is normal for the first time to enter APP from Bootloader.I deinitialize all peripheral such as PIT, SPI before entering bootloader and bootloader will enter APP again. When MCU enter APP from bootloader for the second time, it will stuck at initialzing. I used the library functions offered by IDE. These pictures shows how I find the problem.
1.I find it stuck at here.


2.Then stuck at here in picture 1 function

3.Then stuck at here in picture 2 function

4.Then stuck at here in picture 3 function

5.And finally I found here. It seems that the cycle is waiting a register status until timeout.

6.Then I checked the address of this register, and found out what is the cycle wating for.



But I dont know why this bit stuck at "Mode transition is on going ". Besides, I tried to reduced the TIMEOUT value in picture 5, then the project will stuck at initializing PIT, or SPI, or the others peripheral.