[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <50399556C9727B4D88A595C8584AAB37B4E50431@GSjpTKYDCembx32.service.hitachi.net>
Date: Thu, 17 Mar 2016 12:22:30 +0000
From: 平松雅巳 / HIRAMATU,MASAMI
<masami.hiramatsu.pt@...achi.com>
To: "'David Long'" <dave.long@...aro.org>,
Catalin Marinas <catalin.marinas@....com>,
Will Deacon <will.deacon@....com>,
Sandeepa Prabhu <sandeepa.s.prabhu@...il.com>,
William Cohen <wcohen@...hat.com>,
"Pratyush Anand" <panand@...hat.com>,
Steve Capper <steve.capper@...aro.org>,
"linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Marc Zyngier <marc.zyngier@....com>
CC: Mark Rutland <mark.rutland@....com>,
Petr Mladek <pmladek@...e.com>,
Viresh Kumar <viresh.kumar@...aro.org>,
John Blackwood <john.blackwood@...r.com>,
Feng Kan <fkan@....com>, Zi Shen Lim <zlim.lnx@...il.com>,
Dave P Martin <Dave.Martin@....com>,
Yang Shi <yang.shi@...aro.org>,
Vladimir Murzin <Vladimir.Murzin@....com>,
Kees Cook <keescook@...omium.org>,
"Suzuki K. Poulose" <suzuki.poulose@....com>,
"Mark Brown" <broonie@...nel.org>,
Alex Bennée <alex.bennee@...aro.org>,
Ard Biesheuvel <ard.biesheuvel@...aro.org>,
"Greg Kroah-Hartman" <gregkh@...uxfoundation.org>,
Mark Salyzyn <salyzyn@...roid.com>,
James Morse <james.morse@....com>,
Christoffer Dall <christoffer.dall@...aro.org>,
Andrew Morton <akpm@...ux-foundation.org>,
Robin Murphy <Robin.Murphy@....com>,
Jens Wiklander <jens.wiklander@...aro.org>,
Balamurugan Shanmugam <bshanmugam@....com>,
sysp-manager <cti.systems-productivity-manager.ts@...achi.com>
Subject: RE: [PATCH v11 8/9] arm64: Add kernel return probes support
(kretprobes)
Hi,
>From: Sandeepa Prabhu <sandeepa.s.prabhu@...il.com>
>
>The pre-handler of this special 'trampoline' kprobe executes the return
>probe handler functions and restores original return address in ELR_EL1.
>This way the saved pt_regs still hold the original register context to be
>carried back to the probed kernel function.
This patch seems not well separated.
>diff --git a/arch/arm64/kernel/kprobes.c b/arch/arm64/kernel/kprobes.c
>index bd3f233..13d3333 100644
>--- a/arch/arm64/kernel/kprobes.c
>+++ b/arch/arm64/kernel/kprobes.c
[snip]
>+void __kprobes arch_prepare_kretprobe(struct kretprobe_instance *ri,
>+ struct pt_regs *regs)
>+{
>+ ri->ret_addr = (kprobe_opcode_t *)regs->regs[30];
>+
>+ /* replace return addr (x30) with trampoline */
>+ regs->regs[30] = (long)&kretprobe_trampoline;
So, where is the kretprobe_trampoline? It seems that function is
defined in other patch.
>+}
>+
>+int __kprobes arch_trampoline_kprobe(struct kprobe *p)
>+{
>+ return 0;
> }
And what this function is for??
Thank you,
>
> int __init arch_init_kprobes(void)
>--
>2.5.0
>
>
>_______________________________________________
>linux-arm-kernel mailing list
>linux-arm-kernel@...ts.infradead.org
>http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Powered by blists - more mailing lists