linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ARM: psci: boot_secondary: replace __pa with virt_to_idmap
@ 2015-06-30 10:44 Grygorii Strashko
  2015-06-30 14:50 ` santosh shilimkar
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Grygorii Strashko @ 2015-06-30 10:44 UTC (permalink / raw)
  To: linux-arm-kernel

On some PAE systems (e.g. TI Keystone), memory is above the 32-bit
addressable limit, and the interconnect provides an aliased view of
parts of physical memory in the 32-bit addressable space. This alias
is strictly for boot time usage, and is not otherwise usable because
of coherency limitations.

On such systems, the idmap mechanism has to be used to pass correct
boot address of secondary CPU to FW.
virt_to_idmap() will fall-back to existing virt_to_phys() macro if
such conversation is not required.

Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Nicolas Pitre <nico@linaro.org>
Cc: Santosh Shilimkar <ssantosh@kernel.org>
Cc: Vitaly Andrianov <vitalya@ti.com>
Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
---
 arch/arm/kernel/psci_smp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/kernel/psci_smp.c b/arch/arm/kernel/psci_smp.c
index 28a1db4..244aadd 100644
--- a/arch/arm/kernel/psci_smp.c
+++ b/arch/arm/kernel/psci_smp.c
@@ -51,7 +51,7 @@ static int psci_boot_secondary(unsigned int cpu, struct task_struct *idle)
 {
 	if (psci_ops.cpu_on)
 		return psci_ops.cpu_on(cpu_logical_map(cpu),
-				       __pa(secondary_startup));
+					virt_to_idmap(&secondary_startup));
 	return -ENODEV;
 }
 
-- 
2.4.5

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2015-07-02 10:55 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-30 10:44 [PATCH] ARM: psci: boot_secondary: replace __pa with virt_to_idmap Grygorii Strashko
2015-06-30 14:50 ` santosh shilimkar
2015-06-30 15:05 ` Russell King - ARM Linux
2015-06-30 15:59   ` Nicolas Pitre
2015-06-30 16:28     ` Vitaly Andrianov
2015-06-30 16:18 ` Mark Rutland
2015-06-30 20:25   ` Russell King - ARM Linux
2015-07-02 10:07     ` Grygorii Strashko
2015-07-02 10:29     ` Mark Rutland
2015-07-02 10:39       ` Russell King - ARM Linux
2015-07-02 10:55         ` Mark Rutland

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).