ARC: smp-boot: Decouple Non masters waiting API from jump to entry point
authorVineet Gupta <vgupta@synopsys.com>
Thu, 12 Jan 2017 22:30:29 +0000 (14:30 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 17 Jun 2017 04:41:57 +0000 (06:41 +0200)
commit8cb6045ec40d90d8074dd072c2ec9d0fc7b91956
tree2835ce564c275f03fdb29d39a54ee9ad0450ae07
parentae36f6a65af6f4eaca01cc5b68d8ecb266dbcc17
ARC: smp-boot: Decouple Non masters waiting API from jump to entry point

[ Upstream commit bf02454a741b58682a82c314a9a46bed930ed2f7 ]

For run-on-reset SMP configs, non master cores call a routine which
waits until Master gives it a "go" signal (currently using a shared
mem flag). The same routine then jumps off the well known entry point of
all non Master cores i.e. @first_lines_of_secondary

This patch moves out the last part into one single place in early boot
code.

This is better in terms of absraction (the wait API only waits) and
returns, leaving out the "jump off to" part.

In actual implementation this requires some restructuring of the early
boot code as well as Master now jumps to BSS setup explicitly,
vs. falling thru into it before.

Technically this patch doesn't cause any functional change, it just
moves the ugly #ifdef'ry from assembly code to "C"

Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/arc/kernel/head.S
arch/arc/kernel/smp.c