]> Git Repo - linux.git/commit
kprobes: fix wait_for_kprobe_optimizer()
authorTejun Heo <[email protected]>
Sat, 22 Dec 2012 01:57:00 +0000 (17:57 -0800)
committerTejun Heo <[email protected]>
Sat, 9 Feb 2013 19:32:42 +0000 (11:32 -0800)
commitad72b3bea744b4db01c89af0f86f3e8920d354df
tree8482593d6330783150e88ff7181a1484d3156265
parent7c99e0bf86fdc1dee238eb6e213b980f887b68f1
kprobes: fix wait_for_kprobe_optimizer()

wait_for_kprobe_optimizer() seems largely broken.  It uses
optimizer_comp which is never re-initialized, so
wait_for_kprobe_optimizer() will never wait for anything once
kprobe_optimizer() finishes all pending jobs for the first time.

Also, aside from completion, delayed_work_pending() is %false once
kprobe_optimizer() starts execution and wait_for_kprobe_optimizer()
won't wait for it.

Reimplement it so that it flushes optimizing_work until
[un]optimizing_lists are empty.  Note that this also makes
optimizing_work execute immediately if someone's waiting for it, which
is the nicer behavior.

Only compile tested.

Signed-off-by: Tejun Heo <[email protected]>
Acked-by: Masami Hiramatsu <[email protected]>
Cc: Ananth N Mavinakayanahalli <[email protected]>
Cc: Anil S Keshavamurthy <[email protected]>
Cc: "David S. Miller" <[email protected]>
kernel/kprobes.c
This page took 0.052066 seconds and 4 git commands to generate.