projects/linux·commit 78b1afe2

Merge tag 'perf-urgent-2020-07-25' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip into master

78b1afe2 · Linus Torvalds <[email protected]> · 2020-07-25 13:55:38 -07:00

Pull uprobe fix from Ingo Molnar:
 "Fix an interaction/regression between uprobes based shared library
  tracing & GDB"

* tag 'perf-urgent-2020-07-25' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  uprobes: Change handle_swbp() to send SIGTRAP with si_code=SI_KERNEL, to fix GDB regression
Commit
78b1afe22d51996c1916a332d43b853ff2b10ade
Parents
a7b36c2b · fe5ed7ab

Merge commit. Changes below are compared with the first parent: a7b36c2b.

Changes

1 files changed · +1 −1

FileStatusAddDelContent
kernel/events/uprobes.cmodified+1−1View file

kernel/events/uprobes.c

View file
diff --git a/kernel/events/uprobes.c b/kernel/events/uprobes.c
index bb08628..5f8b0c5 100644
--- a/kernel/events/uprobes.c
+++ b/kernel/events/uprobes.c
@@ -2199,7 +2199,7 @@ static void handle_swbp(struct pt_regs *regs)
if (!uprobe) {
if (is_swbp > 0) {
/* No matching uprobe; signal SIGTRAP. */
- send_sig(SIGTRAP, current, 0);
+ force_sig(SIGTRAP);
} else {
/*
* Either we raced with uprobe_unregister() or we can't