cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
HeroGian91
Observer
Observer
323 Views
Registered: ‎04-28-2020

[Versal] CPU1 failed to come online

Hello,
I'm writing you because I'm trying to test a petalinux image for Versal VCK190. The problem is that after booting Linux, the second CPU (CPU1) fails to go online:

[    0.059927] smp: Bringing up secondary CPUs ...
[    5.114410] CPU1: failed to come online
[    5.118265] CPU1: failed in unknown state : 0x0
[    5.122858] smp: Brought up 1 node, 1 CPU
[    5.131628] CPU features: detected: 32-bit EL0 Support
[    5.136797] CPU features: detected: CRC32 instructions
[    5.141993] CPU: All CPU(s) started at EL2

I also tryied to wake up CPU1 after boot with no luck:

root@xilinx-vck190-2020_1:~# echo 1 > /sys/devices/system/cpu/cpu1/online 
[155174.857617] psci: failed to boot CPU1 (-22)
[155174.861886] CPU1: failed to boot: -22

 This is what I see with xsdb:

     5  APU
        6  Cortex-A72 #0 (Running)
        7  Cortex-A72 #1 (Reset Catch, EL3(S)/A64)

How can I solve the problem?

Thanks

Tags (2)
0 Kudos
5 Replies
aravindb
Moderator
Moderator
261 Views
Registered: ‎02-07-2018

HI @HeroGian91 

I just verified, we can put both  cores online/offline without having any issues.

Here is the logs for your reference:

root@xilinx-vck190-2020_2:~# cat /sys/devices/system/cpu/cpu1/
cpu_capacity crash_notes hotplug/ online regs/ topology/
cpufreq/ crash_notes_size of_node/ power/ subsystem/ uevent
root@xilinx-vck190-2020_2:~# cat /sys/devices/system/cpu/cpu1/online
1
root@xilinx-vck190-2020_2:~# echo 1 > /sys/devices/system/cpu/cpu1/online

root@xilinx-vck190-2020_2:~# cat /sys/devices/system/cpu/cpu0/online
1
root@xilinx-vck190-2020_2:~# cat /sys/devices/system/cpu/cpu1/online
1
root@xilinx-vck190-2020_2:~# echo 0 > /sys/devices/system/cpu/cpu1/online
[ 170.262172] CPU1: shutdown
[ 170.264876] psci: CPU1 killed.
root@xilinx-vck190-2020_2:~#
root@xilinx-vck190-2020_2:~#
root@xilinx-vck190-2020_2:~# echo 1 > /sys/devices/system/cpu/cpu1/online
[ 176.136218] Detected PIPT I-cache on CPU1
[ 176.140240] GICv3: CPU1: found redistributor 1 region 0:0x00000000f90a0000
[ 176.147128] CPU1: Booted secondary processor 0x0000000001 [0x410fd083]
root@xilinx-vck190-2020_2:~#

xsdb% connect
tcfchan#0
xsdb% ta
1 Versal xcvc1902
2 RPU (PS POR is active)
3 Cortex-R5 #0 (PS POR is active)
4 Cortex-R5 #1 (PS POR is active)
5 APU (FPD domain isolation)
6 Cortex-A72 #0 (FPD domain isolation)
7 Cortex-A72 #1 (FPD domain isolation)
8 PPU
9 MicroBlaze PPU (Sleeping after reset)
10 PSM
11 PMC
12 PL
13 DPC
xsdb% ta 6
xsdb% device program BOOT.BIN
100% 10MB 1.3MB/s 00:08
xsdb% ta
1 Versal xcvc1902
2 RPU
3 Cortex-R5 #0 (Halted)
4 Cortex-R5 #1 (Lock Step Mode)
5 APU
6* Cortex-A72 #0 (Running)
7 Cortex-A72 #1 (Running)
8 PPU
9 MicroBlaze PPU (Sleeping)
10 PSM
14 MicroBlaze PSM (Running)
11 PMC
12 PL
13 DPC

 

In your case, looks Cortex-A72 #1 is reset mode, Can you please just select this core 1 from xsdb console & just run "con" command, it should switch to running state.

I recreated the issue just by resetting the core1 & then again ran the "con" command from xsdb then both cores showing running state.

or you can just cold reboot & cross check once. it should work.

 

Thanks & regards

Aravind

----------------------------------------------------------------------------------------------
Kindly note- Please mark the Answer as "Accept as solution" if information provided is helpful.
Give Kudos to a post which you think is helpful and reply oriented.
-------------------------------------------------------------------------------------------

 

 

 

0 Kudos
HeroGian91
Observer
Observer
196 Views
Registered: ‎04-28-2020

Hi @aravindb, thanks for your answer.
I tryied to run CPU1 with xsdb:

xsct% targets                                               
  1* Versal xcvc1902                                        
     2  RPU
        3  Cortex-R5 #0 (Halted)
        4  Cortex-R5 #1 (Lock Step Mode)
     5  APU
        6  Cortex-A72 #0 (Running)
        7  Cortex-A72 #1 (Reset Catch, EL3(S)/A64)
     8  PPU
        9  MicroBlaze PPU (Sleeping)
    10  PSM
       11  MicroBlaze PSM (Running)
    12  PMC
    13  PL
 14  DPC
xsct% target 7                                              
xsct% con                                                   
Info: Cortex-A72 #1 (target 7) Running                      
xsct% targets                                               
  1  Versal xcvc1902                                        
     2  RPU
        3  Cortex-R5 #0 (Halted)
        4  Cortex-R5 #1 (Lock Step Mode)
     5  APU
        6  Cortex-A72 #0 (Running)
        7* Cortex-A72 #1 (Running)
     8  PPU
        9  MicroBlaze PPU (Sleeping)
    10  PSM
       11  MicroBlaze PSM (Running)
    12  PMC
    13  PL
 14  DPC
xsct%   

and then to start the CPU1 also in Linux:

root@vck190:/home/ubuntu# echo 1 > /sys/devices/system/cpu/cpu1/online         
[  386.526302] psci: failed to boot CPU1 (-22)
[  386.530489] CPU1: failed to boot: -22
bash: echo: write error: Invalid argument

but CPU1 does not start.

0 Kudos
aravindb
Moderator
Moderator
193 Views
Registered: ‎02-07-2018

HI @HeroGian91 

Can you please power off your board & power on again.

Once board is powered on you should be able to see both the cores in running state.

 

Thanks & regards

Aravind

0 Kudos
HeroGian91
Observer
Observer
186 Views
Registered: ‎04-28-2020

I tryied to power off and on the board, and this is what I see:

 

xsct% targets                                               
  1  Versal xcvc1902                                        
     2  RPU (PS POR is active)
        3  Cortex-R5 #0 (PS POR is active)
        4  Cortex-R5 #1 (PS POR is active)
     5  APU (FPD domain isolation)
        6  Cortex-A72 #0 (FPD domain isolation)
        7* Cortex-A72 #1 (FPD domain isolation)
     8  PPU
        9  MicroBlaze PPU (Sleeping after reset)
    10  PSM
    12  PMC
    13  PL
 14  DPC

 

when the u-boot is loaded:

 

xsct% targets                                               
  1  Versal xcvc1902                                        
     2  RPU
        3  Cortex-R5 #0 (Halted)
        4  Cortex-R5 #1 (Lock Step Mode)
     5  APU
        6  Cortex-A72 #0 (Running)
        7* Cortex-A72 #1 (Power On Reset)
     8  PPU
        9  MicroBlaze PPU (Sleeping)
    10  PSM
       11  MicroBlaze PSM (Sleeping)
    12  PMC
    13  PL
 14  DPC

 

when petalinux is started:

 

xsct% targets                                               
  1  Versal xcvc1902                                        
     2  RPU
        3  Cortex-R5 #0 (Halted)
        4  Cortex-R5 #1 (Lock Step Mode)
     5  APU
        6  Cortex-A72 #0 (Running)
        7* Cortex-A72 #1 (Reset Catch, EL3(S)/A64)
     8  PPU
        9  MicroBlaze PPU (Sleeping)
    10  PSM
       11  MicroBlaze PSM (Running)
    12  PMC
    13  PL
 14  DPC

 

 

0 Kudos
aravindb
Moderator
Moderator
50 Views
Registered: ‎02-07-2018

Hi @HeroGian91 

I just verified with prebuilt images, but i dont see any issues. We can make cpu1 to online.

Also in kernel logs by default we can see both the cpu's are in online (active). 

For your reference, I added the dmesg logs below along with cpu status in xsdb console  after booting the petalinux.

Note: I used JTAG boot mode. I would like to know which boot mode you are using. I am just doubting on boot mode. if possible can you please try to use JTAG boot mode & try once.

logs:
[ 0.060982] smp: Bringing up secondary CPUs ...
[ 0.162832] Detected PIPT I-cache on CPU1
[ 0.162855] GICv3: CPU1: found redistributor 1 region 0:0x00000000f90a0000
[ 0.162862] GICv3: CPU1: using allocated LPI pending table @0x00000008f8050000
[ 0.162884] CPU1: Booted secondary processor 0x0000000001 [0x410fd083]
[ 0.162940] smp: Brought up 1 node, 2 CPUs
[ 0.191977] SMP: Total of 2 processors activated.
[ 0.196732] CPU features: detected: 32-bit EL0 Support
[ 0.201926] CPU features: detected: CRC32 instructions
[ 0.207148] CPU: All CPU(s) started at EL2
[ 0.211296] alternatives: patching kernel code


root@xilinx-vck190-2020_1:~# cat /sys/devices/system/cpu/cpu1/online
1
root@xilinx-vck190-2020_1:~# cat /sys/devices/system/cpu/cpu0/online
1
root@xilinx-vck190-2020_1:~#
root@xilinx-vck190-2020_1:~#
root@xilinx-vck190-2020_1:~# echo 0 > /sys/devices/system/cpu/cpu1/online
[ 420.551523] CPU1: shutdown
[ 420.554227] psci: CPU1 killed.
root@xilinx-vck190-2020_1:~#
root@xilinx-vck190-2020_1:~# echo 1 > /sys/devices/system/cpu/cpu1/online
[ 734.247478] Detected PIPT I-cache on CPU1
[ 734.251500] GICv3: CPU1: found redistributor 1 region 0:0x00000000f90a0000
[ 734.258388] CPU1: Booted secondary processor 0x0000000001 [0x410fd083]
root@xilinx-vck190-2020_1:~#
root@xilinx-vck190-2020_1:~#
root@xilinx-vck190-2020_1:~#
root@xilinx-vck190-2020_1:~# cat /sys/devices/system/cpu/cpu1/online
1

xsdb% connect
tcfchan#0
xsdb% ta
1 Versal xcvc1902
2 RPU (PS POR is active)
3 Cortex-R5 #0 (PS POR is active)
4 Cortex-R5 #1 (PS POR is active)
5 APU (FPD domain isolation)
6 Cortex-A72 #0 (FPD domain isolation)
7 Cortex-A72 #1 (FPD domain isolation)
8 PPU
9 MicroBlaze PPU (Sleeping after reset)
10 PSM
11 PMC
12 PL
13 DPC
xsdb% ta 6
xsdb%
xsdb% ta
1 Versal xcvc1902
2 RPU (PS POR is active)
3 Cortex-R5 #0 (PS POR is active)
4 Cortex-R5 #1 (PS POR is active)
5 APU (FPD domain isolation)
6* Cortex-A72 #0 (FPD domain isolation)
7 Cortex-A72 #1 (FPD domain isolation)
8 PPU
9 MicroBlaze PPU (Sleeping after reset)
10 PSM
11 PMC
12 PL
13 DPC
xsdb% device program BOOT.BIN
100% 10MB 1.4MB/s 00:07
xsdb% ta
1 Versal xcvc1902
2 RPU
3 Cortex-R5 #0 (Halted)
4 Cortex-R5 #1 (Lock Step Mode)
5 APU
6* Cortex-A72 #0 (Running)
7 Cortex-A72 #1 (Running)
8 PPU
9 MicroBlaze PPU (Sleeping)
10 PSM
14 MicroBlaze PSM (Running)
11 PMC
12 PL
13 DPC
xsdb%
xsdb% ta
1 Versal xcvc1902
2 RPU
3 Cortex-R5 #0 (Halted)
4 Cortex-R5 #1 (Lock Step Mode)
5 APU
6* Cortex-A72 #0 (Running)
7 Cortex-A72 #1 (No Power)
8 PPU
9 MicroBlaze PPU (Sleeping)
10 PSM
14 MicroBlaze PSM (Running)
11 PMC
12 PL
13 DPC
xsdb% ta
1 Versal xcvc1902
2 RPU
3 Cortex-R5 #0 (Halted)
4 Cortex-R5 #1 (Lock Step Mode)
5 APU
6* Cortex-A72 #0 (Running)
7 Cortex-A72 #1 (Running)
8 PPU
9 MicroBlaze PPU (Sleeping)
10 PSM
14 MicroBlaze PSM (Running)
11 PMC
12 PL
13 DPC
xsdb%

 

Thanks & regards

Aravind

 

 

0 Kudos