• Max Filippov's avatar
    xtensa: SMP: fix secondary CPU initialization · 8655802a
    Max Filippov authored
    [ Upstream commit 32a7726c ]
    
    - add missing memory barriers to the secondary CPU synchronization spin
      loops; add comment to the matching memory barrier in the boot_secondary
      and __cpu_die functions;
    - use READ_ONCE/WRITE_ONCE to access cpu_start_id/cpu_start_ccount
      instead of reading/writing them directly;
    - re-initialize cpu_running every time before starting secondary CPU to
      flush possible previous CPU startup results.
    Signed-off-by: default avatarMax Filippov <jcmvbkbc@gmail.com>
    Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
    8655802a
head.S 6.85 KB