X-Git-Url: http://git.monstr.eu/?p=linux-2.6-microblaze.git;a=blobdiff_plain;f=kernel%2Fkprobes.c;h=3b61ae8ff5da1dc62cfdf2def8acff3eaec2c322;hp=732a70163584a05e1c532653bdfdfb68b807f994;hb=bcb53209be5cb32d485507452edda19b78f31d84;hpb=319f0ce284fff8e4f95167cb144acc905d0584c7 diff --git a/kernel/kprobes.c b/kernel/kprobes.c index 732a70163584..3b61ae8ff5da 100644 --- a/kernel/kprobes.c +++ b/kernel/kprobes.c @@ -2235,9 +2235,10 @@ static void kill_kprobe(struct kprobe *p) /* * The module is going away. We should disarm the kprobe which - * is using ftrace. + * is using ftrace, because ftrace framework is still available at + * MODULE_STATE_GOING notification. */ - if (kprobe_ftrace(p)) + if (kprobe_ftrace(p) && !kprobe_disabled(p) && !kprobes_all_disarmed) disarm_kprobe_ftrace(p); }