Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753730AbcDSKQg (ORCPT ); Tue, 19 Apr 2016 06:16:36 -0400 Received: from ozlabs.org ([103.22.144.67]:44822 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753431AbcDSKQe (ORCPT ); Tue, 19 Apr 2016 06:16:34 -0400 X-powerpc-patch-notification: thanks X-powerpc-patch-commit: 28e7cbd3e0f5fefec892842d1391ebd508fdb5ce In-Reply-To: <1460552003-15409-3-git-send-email-mpe@ellerman.id.au> To: Michael Ellerman , From: Michael Ellerman Cc: pmladek@suse.com, jeyu@redhat.com, jikos@kernel.org, linux-kernel@vger.kernel.org, rostedt@goodmis.org, kamalesh@linux.vnet.ibm.com, duwe@lst.de, live-patching@vger.kernel.org, mbenes@suse.cz Subject: Re: [2/5] livepatch: Allow architectures to specify an alternate ftrace location Message-Id: <3qq1Bj3wbTz9t8k@ozlabs.org> Date: Tue, 19 Apr 2016 20:16:29 +1000 (AEST) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 818 Lines: 20 On Wed, 2016-13-04 at 12:53:20 UTC, Michael Ellerman wrote: > When livepatch tries to patch a function it takes the function address > and asks ftrace to install the livepatch handler at that location. > ftrace will look for an mcount call site at that exact address. > > On powerpc the mcount location is not the first instruction of the > function, and in fact it's not at a constant offset from the start of > the function. To accommodate this add a hook which arch code can > override to customise the behaviour. > > Signed-off-by: Torsten Duwe > Signed-off-by: Balbir Singh > Signed-off-by: Petr Mladek > Signed-off-by: Michael Ellerman Applied to powerpc next. https://git.kernel.org/powerpc/c/28e7cbd3e0f5fefec892842d13 cheers