diff options
author | Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com> | 2017-06-29 23:19:20 +0530 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2017-07-03 23:12:02 +1000 |
commit | 90653a84052cfbbc1f46427f851dad14083e36df (patch) | |
tree | b0fb0dc0ce158690b2738510de98489aa27eb031 /arch | |
parent | 15770a13bebc7fae2fbc06bc4cc708a3f724c586 (diff) | |
download | linux-stable-90653a84052cfbbc1f46427f851dad14083e36df.tar.gz linux-stable-90653a84052cfbbc1f46427f851dad14083e36df.tar.bz2 linux-stable-90653a84052cfbbc1f46427f851dad14083e36df.zip |
powerpc/64s: Blacklist rtas entry/exit from kprobes
We can't take traps with relocation off, so blacklist enter_rtas() and
rtas_return_loc(). However, instead of blacklisting all of enter_rtas(),
introduce a new symbol __enter_rtas from where on we can't take a trap
and blacklist that.
Signed-off-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/powerpc/kernel/entry_64.S | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/entry_64.S b/arch/powerpc/kernel/entry_64.S index d5be463b2fa4..49d8422767b4 100644 --- a/arch/powerpc/kernel/entry_64.S +++ b/arch/powerpc/kernel/entry_64.S @@ -1091,6 +1091,8 @@ _GLOBAL(enter_rtas) rldicr r9,r9,MSR_SF_LG,(63-MSR_SF_LG) ori r9,r9,MSR_IR|MSR_DR|MSR_FE0|MSR_FE1|MSR_FP|MSR_RI|MSR_LE andc r6,r0,r9 + +__enter_rtas: sync /* disable interrupts so SRR0/1 */ mtmsrd r0 /* don't get trashed */ @@ -1127,6 +1129,8 @@ rtas_return_loc: mtspr SPRN_SRR1,r4 rfid b . /* prevent speculative execution */ +_ASM_NOKPROBE_SYMBOL(__enter_rtas) +_ASM_NOKPROBE_SYMBOL(rtas_return_loc) .align 3 1: .llong rtas_restore_regs |