linux/arch
Anshuman Khandual b98cca444d mm, kprobes: generalize and rename notify_page_fault() as kprobe_page_fault()
Architectures which support kprobes have very similar boilerplate around
calling kprobe_fault_handler().  Use a helper function in kprobes.h to
unify them, based on the x86 code.

This changes the behaviour for other architectures when preemption is
enabled.  Previously, they would have disabled preemption while calling
the kprobe handler.  However, preemption would be disabled if this fault
was due to a kprobe, so we know the fault was not due to a kprobe
handler and can simply return failure.

This behaviour was introduced in commit a980c0ef9f ("x86/kprobes:
Refactor kprobes_fault() like kprobe_exceptions_notify()")

[anshuman.khandual@arm.com: export kprobe_fault_handler()]
  Link: http://lkml.kernel.org/r/1561133358-8876-1-git-send-email-anshuman.khandual@arm.com
Link: http://lkml.kernel.org/r/1560420444-25737-1-git-send-email-anshuman.khandual@arm.com
Signed-off-by: Anshuman Khandual <anshuman.khandual@arm.com>
Reviewed-by: Dave Hansen <dave.hansen@linux.intel.com>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Matthew Wilcox <willy@infradead.org>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Christophe Leroy <christophe.leroy@c-s.fr>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Andrey Konovalov <andreyknvl@google.com>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Russell King <linux@armlinux.org.uk>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will.deacon@arm.com>
Cc: Tony Luck <tony.luck@intel.com>
Cc: Fenghua Yu <fenghua.yu@intel.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Andy Lutomirski <luto@kernel.org>
Cc: Vineet Gupta <vgupta@synopsys.com>
Cc: James Hogan <jhogan@kernel.org>
Cc: Paul Burton <paul.burton@mips.com>
Cc: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2019-07-16 19:23:22 -07:00
..
alpha arch/*: remove unused isa_page_to_bus() 2019-07-16 19:23:22 -07:00
arc arch: replace _BITUL() in kernel-space headers with BIT() 2019-07-16 19:23:22 -07:00
arm mm, kprobes: generalize and rename notify_page_fault() as kprobe_page_fault() 2019-07-16 19:23:22 -07:00
arm64 mm, kprobes: generalize and rename notify_page_fault() as kprobe_page_fault() 2019-07-16 19:23:22 -07:00
c6x Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu 2019-07-10 21:42:03 -07:00
csky Kconfig updates for v5.3 2019-07-12 16:06:27 -07:00
h8300 Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu 2019-07-10 21:42:03 -07:00
hexagon Merge branch 'siginfo-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace 2019-07-08 21:48:15 -07:00
ia64 mm, kprobes: generalize and rename notify_page_fault() as kprobe_page_fault() 2019-07-16 19:23:22 -07:00
m68k Merge branch 'akpm' (patches from Andrew) 2019-07-12 11:40:28 -07:00
microblaze clone3-v5.3 2019-07-11 10:09:44 -07:00
mips mm, kprobes: generalize and rename notify_page_fault() as kprobe_page_fault() 2019-07-16 19:23:22 -07:00
nds32 Kconfig updates for v5.3 2019-07-12 16:06:27 -07:00
nios2 nios2 update for v5.3-rc1 2019-07-12 15:38:05 -07:00
openrisc dma-mapping updates for Linux 5.3 2019-07-12 15:13:55 -07:00
parisc Kbuild updates for v5.3 2019-07-12 16:03:16 -07:00
powerpc mm, kprobes: generalize and rename notify_page_fault() as kprobe_page_fault() 2019-07-16 19:23:22 -07:00
riscv Kconfig updates for v5.3 2019-07-12 16:06:27 -07:00
s390 mm, kprobes: generalize and rename notify_page_fault() as kprobe_page_fault() 2019-07-16 19:23:22 -07:00
sh mm, kprobes: generalize and rename notify_page_fault() as kprobe_page_fault() 2019-07-16 19:23:22 -07:00
sparc mm, kprobes: generalize and rename notify_page_fault() as kprobe_page_fault() 2019-07-16 19:23:22 -07:00
um This pull request contains the following changes for UML: 2019-07-14 17:17:34 -07:00
unicore32 Kconfig updates for v5.3 2019-07-12 16:06:27 -07:00
x86 mm, kprobes: generalize and rename notify_page_fault() as kprobe_page_fault() 2019-07-16 19:23:22 -07:00
xtensa mm: fix the MAP_UNINITIALIZED flag 2019-07-16 19:23:21 -07:00
.gitignore
Kconfig