From: pmladek@suse.com (Petr Mladek)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 0/7] arm: Add livepatch support
Date: Wed, 7 Dec 2016 16:19:48 +0100 [thread overview]
Message-ID: <20161207151948.GE13288@linux.suse> (raw)
In-Reply-To: <1481043967-15602-1-git-send-email-abelvesa@linux.com>
On Tue 2016-12-06 17:06:00, Abel Vesa wrote:
> This is just an idea I've been trying out for a while now.
>
> Just in case somebody wants to play with it, this applies to linux-arm/for-next.
>
> Also please note that this was only tested in qemu, but I will do some testing
> on some real hardware in the following days.
>
> FWICT, on this arch the compiler always generates a function prologue somewhere
> between these lines:
>
> e1a0c00d mov ip, sp
> e92ddff0 push {r4-r9, sl, fp, ip, lr, pc}
> e24cb004 sub fp, ip, #4
> e24dd064 sub sp, sp, #100 ; 0x64 <--- local variables
> e52de004 push {lr} ; (str lr, [sp, #-4]!)
> ebf9c2c9 bl 80110364 <__gnu_mcount_nc>
> ....
>
> Every function that follows this pattern (the number of registers pushed and the
> sp subtraction for the local variables being the only acceptable exception) can
> be patched with this mechanism. IIRC, only the inline functions and notrace
> functions do not follow this pattern.
Please, where do you check that the given function follows this
pattern? I do not have experience with arm at all. But compiler
is able to do crazy optimizations these days.
I think that this was already mentioned somewhere. But please, put
this detailed explanation also to related patch/code so that it
can later be found in the git commits. It will also help to
better understand/review the particular patches.
Best Regards,
Petr
prev parent reply other threads:[~2016-12-07 15:19 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-06 17:06 [PATCH 0/7] arm: Add livepatch support Abel Vesa
2016-12-06 17:06 ` [PATCH 1/7] arm: Add livepatch arch specific code Abel Vesa
2017-01-16 16:47 ` Miroslav Benes
2017-01-17 0:22 ` Jessica Yu
2017-01-17 2:27 ` Jessica Yu
2017-01-17 13:53 ` Miroslav Benes
2016-12-06 17:06 ` [PATCH 2/7] arm: ftrace: Add call modify mechanism Abel Vesa
2016-12-07 10:37 ` kbuild test robot
2016-12-06 17:06 ` [PATCH 3/7] arm: module: Add apply_relocate_add Abel Vesa
2016-12-07 2:08 ` kbuild test robot
2017-01-17 4:49 ` Jessica Yu
2017-01-18 10:37 ` Miroslav Benes
2016-12-06 17:06 ` [PATCH 4/7] arm: Add ftrace with regs support Abel Vesa
2016-12-07 2:43 ` Steven Rostedt
2016-12-07 10:57 ` Russell King - ARM Linux
2016-12-07 11:58 ` Robin Murphy
2016-12-07 12:10 ` Abel Vesa
2016-12-06 17:06 ` [PATCH 5/7] arm: ftrace: Add ARCH_SUPPORTS_FTRACE_OPS for ftrace with regs Abel Vesa
2016-12-06 17:06 ` [PATCH 6/7] arm: Add livepatch to build if CONFIG_LIVEPATCH Abel Vesa
2016-12-07 15:05 ` Petr Mladek
2016-12-07 16:11 ` Abel Vesa
2017-01-18 12:36 ` Miroslav Benes
2016-12-06 17:06 ` [PATCH 7/7] arm: Add livepatch necessary arch selects into Kconfig Abel Vesa
2016-12-07 2:45 ` Steven Rostedt
2016-12-07 6:48 ` kbuild test robot
2017-01-18 12:40 ` Miroslav Benes
2017-01-18 13:35 ` Russell King - ARM Linux
2016-12-07 1:35 ` [PATCH 0/7] arm: Add livepatch support zhouchengming
2016-12-07 1:38 ` zhouchengming
2016-12-07 11:39 ` Abel Vesa
2016-12-07 15:19 ` Petr Mladek [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20161207151948.GE13288@linux.suse \
--to=pmladek@suse.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).