Re: [RFC PATCH][3.0] Tracepoint: dissociate from module mutex (v2)

From: Steven Rostedt
Date: Wed Aug 10 2011 - 23:23:32 EST

On Thu, 2011-08-11 at 12:14 +0900, Masami Hiramatsu wrote:
> (2011/08/11 4:18), Mathieu Desnoyers wrote:
> > Copy the information needed from struct module into a local module list
> > held within tracepoint.c from within the module coming/going notifier.
> >
> > This vastly simplifies locking of tracepoint registration /
> > unregistration, because we don't have to take the module mutex to
> > register and unregister tracepoints anymore. Steven Rostedt ran into
> > dependency problems related to modules mutex vs kprobes mutex vs ftrace
> > mutex vs tracepoint mutex that seems to be hard to fix without removing
> > this dependency between tracepoint and module mutex. (note: it should be
> > investigated whether kprobes could benefit of being dissociated from the
> > modules mutex too.)
> Thanks, it seems that kprobes has already mostly done that.
> It holds module_mutex only in kprobe_optimizer. However,
> it seems meaningless, because kprobe_mutex already protects
> kprobe_optimizer against the kprobes module notifier.
> Thus, a module removing will stays on the notifier until
> the optimizer runs out. So I think we can remove that mutex lock.

So should I change my patch 4/5 to just remove the module_mutex?

[PATCH 4/5][RFC] kprobes: Inverse taking of module_mutex with kprobe_mutex

-- Steve

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at