From mboxrd@z Thu Jan 1 00:00:00 1970 From: will.deacon@arm.com (Will Deacon) Date: Thu, 20 Oct 2016 15:31:05 +0100 Subject: [PATCH] arm64/kprobes: Tidy up sign-extension usage In-Reply-To: References: Message-ID: <20161020143105.GF24914@arm.com> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On Tue, Oct 18, 2016 at 01:46:27PM +0100, Robin Murphy wrote: > Kprobes does not need its own homebrewed (and frankly inscrutable) sign > extension macro; just use the standard kernel functions instead. Since > the compiler actually recognises the sign-extension idiom of the latter, > we also get the small bonus of some nicer codegen, as each displacement > calculation helper then compiles to a single optimal SBFX instruction. > > Signed-off-by: Robin Murphy > --- > arch/arm64/kernel/probes/simulate-insn.c | 16 +++++++--------- > 1 file changed, 7 insertions(+), 9 deletions(-) Acked-by: Will Deacon Will