arm64: Fix size of __early_cpu_boot_status
__early_cpu_boot_status is of type long. Use quad
assembler directive to allocate proper size.
--- arch/arm64/kernel/head.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/kernel/head.S +1 -1
@@ -684,7 +684,7 @@ ENTRY(__boot_cpu_mode) * with MMU turned off. */ ENTRY(__early_cpu_boot_status) - .long 0 + .quad 0 .popsection
Signature · 7 lines
1.9.1 _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Quoted 13 lines · Arun KS
__early_cpu_boot_statusis of type long. Use quad
assembler directive to allocate proper size.Signed-off-by Arun KS <[email protected]>--- arch/arm64/kernel/head.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)arch/arm64/kernel/head.S +0
-0
arch/arm64/kernel/head.S ENTRY(__boot_cpu_mode) · line 687
Quoted 5 lines
arch/arm64/kernel/head.S +1
-1@@ -684,7 +684,7 @@ ENTRY(__boot_cpu_mode) * with MMU turned off. */ ENTRY(__early_cpu_boot_status) - .long 0 + .quad 0
Yikes. How did you spot this? Did we end up corrupting an adjacent variable, or does the alignment in the linker script save us in practice?
Will
Quoted 10 lines · Will Deacon
Quoted 8 lines · Arun KS
__early_cpu_boot_statusis of type long. Use quad
assembler directive to allocate proper size.Signed-off-by Arun KS <[email protected]>--- arch/arm64/kernel/head.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Quoted 13 lines
arch/arm64/kernel/head.S ENTRY(__boot_cpu_mode) · line 687
Quoted 10 lines
arch/arm64/kernel/head.S +1
-1@@ -684,7 +684,7 @@ ENTRY(__boot_cpu_mode) * with MMU turned off. */ ENTRY(__early_cpu_boot_status) - .long 0 + .quad 0Yikes. How did you spot this? Did we end up corrupting an adjacent variable, or does the alignment in the linker script save us in practice?
Rite now there is no adjacent variable. But I was adding one and it was getting corrupted.
Regards,
Arun
Quoted 2 lines
Will
_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Quoted 13 lines · Arun KS
__early_cpu_boot_statusis of type long. Use quad
assembler directive to allocate proper size.Signed-off-by Arun KS <[email protected]>--- arch/arm64/kernel/head.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)arch/arm64/kernel/head.S +0
-0
arch/arm64/kernel/head.S ENTRY(__boot_cpu_mode) · line 687
Quoted 5 lines
arch/arm64/kernel/head.S +1
-1@@ -684,7 +684,7 @@ ENTRY(__boot_cpu_mode) * with MMU turned off. */ ENTRY(__early_cpu_boot_status) - .long 0 + .quad 0
This is the last element in .mmuoff.data.write, which is padded to 2K, so luckily we don't clobber anything else (and don't need a backport).
For consistency with __boot_cpu_mode, we could instead change the c declaration to int, and fix up the calls to update_early_cpu_boot_status, to use a w register, but either way:
Mark.
Quoted 11 lines
arch/arm64/kernel/head.S +0
-0.popsectionSignature · 7 lines
1.9.1 _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel