powerpc/82xx: Blacklist pq2_restart() for kprobe
authorChristophe Leroy <christophe.leroy@c-s.fr>
Tue, 31 Mar 2020 16:03:37 +0000 (16:03 +0000)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 2 Jun 2020 10:59:09 +0000 (20:59 +1000)
kprobe does not handle events happening in real mode, all
functions running with MMU disabled have to be blacklisted.

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Acked-by: Naveen N. Rao <naveen.n.rao@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/5dca36682383577a3c2b2bca4d577e8654944461.1585670437.git.christophe.leroy@c-s.fr
arch/powerpc/platforms/82xx/pq2.c

index 1cdd5ed..3b5cb39 100644 (file)
@@ -10,6 +10,8 @@
  * Copyright (c) 2006 MontaVista Software, Inc.
  */
 
+#include <linux/kprobes.h>
+
 #include <asm/cpm2.h>
 #include <asm/io.h>
 #include <asm/pci-bridge.h>
@@ -29,6 +31,7 @@ void __noreturn pq2_restart(char *cmd)
 
        panic("Restart failed\n");
 }
+NOKPROBE_SYMBOL(pq2_restart)
 
 #ifdef CONFIG_PCI
 static int pq2_pci_exclude_device(struct pci_controller *hose,