[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200109160300.26150-54-jthierry@redhat.com>
Date: Thu, 9 Jan 2020 16:02:56 +0000
From: Julien Thierry <jthierry@...hat.com>
To: linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org
Cc: jpoimboe@...hat.com, peterz@...radead.org, raphael.gault@....com,
catalin.marinas@....com, will@...nel.org,
Julien Thierry <jthierry@...hat.com>
Subject: [RFC v5 53/57] arm64: Generate no-ops to pad executable section
Directive .org fills the gap left to get to the new location with bytes
of value 0.
Having an executable section contain invalid opcodes confuses objtool,
so use .balign to fill the gap with nop instructions instead.
Signed-off-by: Julien Thierry <jthierry@...hat.com>
---
arch/arm64/kernel/relocate_kernel.S | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/arm64/kernel/relocate_kernel.S b/arch/arm64/kernel/relocate_kernel.S
index c1d7db71a726..5e08845f701a 100644
--- a/arch/arm64/kernel/relocate_kernel.S
+++ b/arch/arm64/kernel/relocate_kernel.S
@@ -118,6 +118,8 @@ ENDPROC(arm64_relocate_new_kernel)
.align 3 /* To keep the 64-bit values below naturally aligned. */
.Lcopy_end:
+.balign KEXEC_CONTROL_PAGE_SIZE
+/* Ensure we didn't go past the limit */
.org KEXEC_CONTROL_PAGE_SIZE
/*
--
2.21.0
Powered by blists - more mailing lists