diff mbox

ARM: mm: use virt_to_idmap to get phys_reset address

Message ID 1433254470-26507-1-git-send-email-vitalya@ti.com (mailing list archive)
State New, archived
Headers show

Commit Message

Vitaly Andrianov June 2, 2015, 2:14 p.m. UTC
This patch is to get correct physical address of the reset function for
PAE systems, which use aliased physical memory for booting.

See the "ARM: mm: Introduce virt_to_idmap() with an arch hook" for details.

Signed-off-by: Vitaly Andrianov <vitalya@ti.com>
---
 arch/arm/kernel/reboot.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Russell King - ARM Linux July 6, 2015, 2:41 p.m. UTC | #1
On Tue, Jun 02, 2015 at 10:14:30AM -0400, Vitaly Andrianov wrote:
> This patch is to get correct physical address of the reset function for
> PAE systems, which use aliased physical memory for booting.
> 
> See the "ARM: mm: Introduce virt_to_idmap() with an arch hook" for details.
> 
> Signed-off-by: Vitaly Andrianov <vitalya@ti.com>

Please send this to the patch system, thanks.
diff mbox

Patch

diff --git a/arch/arm/kernel/reboot.c b/arch/arm/kernel/reboot.c
index 1a4d232..3826935 100644
--- a/arch/arm/kernel/reboot.c
+++ b/arch/arm/kernel/reboot.c
@@ -50,7 +50,7 @@  static void __soft_restart(void *addr)
 	flush_cache_all();
 
 	/* Switch to the identity mapping. */
-	phys_reset = (phys_reset_t)(unsigned long)virt_to_phys(cpu_reset);
+	phys_reset = (phys_reset_t)(unsigned long)virt_to_idmap(cpu_reset);
 	phys_reset((unsigned long)addr);
 
 	/* Should never get here. */