From: Luis Araneda <luaraneda@gmail.com>
To: linux@armlinux.org.uk, michal.simek@xilinx.com
Cc: Luis Araneda <luaraneda@gmail.com>,
linux-arm-kernel@lists.infradead.org, stable@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: [PATCH 1/2] ARM: zynq: support smp in thumb mode
Date: Mon, 5 Aug 2019 23:07:17 -0400 [thread overview]
Message-ID: <20190806030718.29048-2-luaraneda@gmail.com> (raw)
In-Reply-To: <20190806030718.29048-1-luaraneda@gmail.com>
Add .arm directive to headsmp.S to ensure that the
CPU starts in 32-bit ARM mode and the correct code
size is copied on smp bring-up
Additionally, start secondary CPUs on secondary_startup_arm
to automatically switch from ARM to thumb on a thumb kernel
Suggested-by: Michal Simek <michal.simek@xilinx.com>
Signed-off-by: Luis Araneda <luaraneda@gmail.com>
---
arch/arm/mach-zynq/headsmp.S | 2 ++
arch/arm/mach-zynq/platsmp.c | 2 +-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-zynq/headsmp.S b/arch/arm/mach-zynq/headsmp.S
index ab85003cf9ad..3449e0d1f990 100644
--- a/arch/arm/mach-zynq/headsmp.S
+++ b/arch/arm/mach-zynq/headsmp.S
@@ -7,6 +7,8 @@
#include <linux/init.h>
#include <asm/assembler.h>
+ .arm
+
ENTRY(zynq_secondary_trampoline)
ARM_BE8(setend be) @ ensure we are in BE8 mode
ldr r0, zynq_secondary_trampoline_jump
diff --git a/arch/arm/mach-zynq/platsmp.c b/arch/arm/mach-zynq/platsmp.c
index a7cfe07156f4..38728badabd4 100644
--- a/arch/arm/mach-zynq/platsmp.c
+++ b/arch/arm/mach-zynq/platsmp.c
@@ -81,7 +81,7 @@ EXPORT_SYMBOL(zynq_cpun_start);
static int zynq_boot_secondary(unsigned int cpu, struct task_struct *idle)
{
- return zynq_cpun_start(__pa_symbol(secondary_startup), cpu);
+ return zynq_cpun_start(__pa_symbol(secondary_startup_arm), cpu);
}
/*
--
2.22.0
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
WARNING: multiple messages have this Message-ID (diff)
From: Luis Araneda <luaraneda@gmail.com>
To: linux@armlinux.org.uk, michal.simek@xilinx.com
Cc: stable@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, Luis Araneda <luaraneda@gmail.com>
Subject: [PATCH 1/2] ARM: zynq: support smp in thumb mode
Date: Mon, 5 Aug 2019 23:07:17 -0400 [thread overview]
Message-ID: <20190806030718.29048-2-luaraneda@gmail.com> (raw)
In-Reply-To: <20190806030718.29048-1-luaraneda@gmail.com>
Add .arm directive to headsmp.S to ensure that the
CPU starts in 32-bit ARM mode and the correct code
size is copied on smp bring-up
Additionally, start secondary CPUs on secondary_startup_arm
to automatically switch from ARM to thumb on a thumb kernel
Suggested-by: Michal Simek <michal.simek@xilinx.com>
Signed-off-by: Luis Araneda <luaraneda@gmail.com>
---
arch/arm/mach-zynq/headsmp.S | 2 ++
arch/arm/mach-zynq/platsmp.c | 2 +-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-zynq/headsmp.S b/arch/arm/mach-zynq/headsmp.S
index ab85003cf9ad..3449e0d1f990 100644
--- a/arch/arm/mach-zynq/headsmp.S
+++ b/arch/arm/mach-zynq/headsmp.S
@@ -7,6 +7,8 @@
#include <linux/init.h>
#include <asm/assembler.h>
+ .arm
+
ENTRY(zynq_secondary_trampoline)
ARM_BE8(setend be) @ ensure we are in BE8 mode
ldr r0, zynq_secondary_trampoline_jump
diff --git a/arch/arm/mach-zynq/platsmp.c b/arch/arm/mach-zynq/platsmp.c
index a7cfe07156f4..38728badabd4 100644
--- a/arch/arm/mach-zynq/platsmp.c
+++ b/arch/arm/mach-zynq/platsmp.c
@@ -81,7 +81,7 @@ EXPORT_SYMBOL(zynq_cpun_start);
static int zynq_boot_secondary(unsigned int cpu, struct task_struct *idle)
{
- return zynq_cpun_start(__pa_symbol(secondary_startup), cpu);
+ return zynq_cpun_start(__pa_symbol(secondary_startup_arm), cpu);
}
/*
--
2.22.0
next prev parent reply other threads:[~2019-08-06 3:08 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-06 3:07 [PATCH 0/2] ARM: zynq: smp improvements Luis Araneda
2019-08-06 3:07 ` Luis Araneda
2019-08-06 3:07 ` Luis Araneda [this message]
2019-08-06 3:07 ` [PATCH 1/2] ARM: zynq: support smp in thumb mode Luis Araneda
2019-08-06 5:17 ` Greg KH
2019-08-06 5:17 ` Greg KH
2019-08-06 6:39 ` Michal Simek
2019-08-06 6:39 ` Michal Simek
2019-08-06 12:40 ` Luis Araneda
2019-08-06 12:40 ` Luis Araneda
2019-08-08 9:18 ` Michal Simek
2019-08-08 9:18 ` Michal Simek
2019-08-06 3:07 ` [PATCH 2/2] ARM: zynq: Use memcpy_toio instead of memcpy on smp bring-up Luis Araneda
2019-08-06 3:07 ` Luis Araneda
2019-08-06 5:17 ` Greg KH
2019-08-06 5:17 ` Greg KH
2019-08-06 6:41 ` Michal Simek
2019-08-06 6:41 ` Michal Simek
2019-08-06 12:49 ` Luis Araneda
2019-08-06 12:49 ` Luis Araneda
2019-08-08 9:19 ` Michal Simek
2019-08-08 9:19 ` Michal Simek
2019-08-06 5:17 ` [PATCH 0/2] ARM: zynq: smp improvements Greg KH
2019-08-06 5:17 ` Greg KH
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190806030718.29048-2-luaraneda@gmail.com \
--to=luaraneda@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=michal.simek@xilinx.com \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.