From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754570AbdBISPL (ORCPT ); Thu, 9 Feb 2017 13:15:11 -0500 Received: from mail.kernel.org ([198.145.29.136]:43078 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752817AbdBISPE (ORCPT ); Thu, 9 Feb 2017 13:15:04 -0500 Date: Thu, 9 Feb 2017 13:14:52 -0500 From: Steven Rostedt To: Russell King - ARM Linux Cc: Abel Vesa , mingo@redhat.com, viro@zeniv.linux.org.uk, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, jjhiblot@traphandler.com, pmladek@suse.com, robin.murphy@arm.com, zhouchengming1@huawei.com, Masami Hiramatsu Subject: Re: [PATCHv3] arm: ftrace: Adds support for CONFIG_DYNAMIC_FTRACE_WITH_REGS Message-ID: <20170209131452.472aa882@gandalf.local.home> In-Reply-To: <20170209131414.098c848c@gandalf.local.home> References: <1486508275-18449-1-git-send-email-abelvesa@linux.com> <20170209162956.GH27312@n2100.armlinux.org.uk> <20170209121322.5229e6cf@gandalf.local.home> <20170209180644.GJ27312@n2100.armlinux.org.uk> <20170209131414.098c848c@gandalf.local.home> X-Mailer: Claws Mail 3.14.0 (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [ sending again with Masami Cc'd ] On Thu, 9 Feb 2017 13:14:14 -0500 Steven Rostedt wrote: > On Thu, 9 Feb 2017 18:06:44 +0000 > Russell King - ARM Linux wrote: > > > On Thu, Feb 09, 2017 at 12:13:22PM -0500, Steven Rostedt wrote: > > > Then came along live kernel patching, which I believe this series is > > > trying to support. What is needed by pt_regs is a way to "hijack" the > > > function being called to instead call the patched function. That is, > > > ftrace is not being used for tracing, but in reality, being used to > > > modify the running kernel. It is being used to change what function > > > gets called. ftrace is just a hook for that mechanism. > > > > So, would I be correct to assume that the only parts of pt_regs that > > would be touched are those which contain arguments to the function, > > and the register which would contain the return value? > > > > For live kernel patching, perhaps. > > But for kprobes, I think they can touch anything. Matters what the > creater of the kprobe wanted to do. > > -- Steve