]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
powerpc/kprobe: Complete kprobe and migrate exception frame
authorTiejun Chen <tiejun.chen@windriver.com>
Sun, 16 Sep 2012 23:54:30 +0000 (23:54 +0000)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Tue, 18 Sep 2012 05:32:42 +0000 (15:32 +1000)
commita9c4e541ea9b22944da356f2a9258b4eddcc953b
tree3231ff5c12366200c5f5d48e654415e628a231f0
parentf0d1128fcb919a73941a54f80efab04fa3160dfe
powerpc/kprobe: Complete kprobe and migrate exception frame

We can't emulate stwu since that may corrupt current exception stack.
So we will have to do real store operation in the exception return code.

Firstly we'll allocate a trampoline exception frame below the kprobed
function stack and copy the current exception frame to the trampoline.
Then we can do this real store operation to implement 'stwu', and reroute
the trampoline frame to r1 to complete this exception migration.

Signed-off-by: Tiejun Chen <tiejun.chen@windriver.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/kernel/entry_32.S
arch/powerpc/kernel/entry_64.S