diff options
author | Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> | 2013-05-16 20:48:49 +0900 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2013-05-16 11:01:16 -0400 |
commit | 6ed0106667d76589cb648c27edb4f4ffbf9d59ca (patch) | |
tree | 703a6db004b022ddebdfaf186c66e5bfabc03e5f /kernel/mutex.h | |
parent | b62fdd97fcae17e483b005bafd13fadbd9840672 (diff) | |
download | linux-6ed0106667d76589cb648c27edb4f4ffbf9d59ca.tar.bz2 |
tracing: Return -EBUSY when event_enable_func() fails to get module
Since try_module_get() returns false( = 0) when it fails to
pindown a module, event_enable_func() returns 0 which means
"succeed". This can cause a kernel panic when the entry
is removed, because the event is already released.
This fixes the bug by returning -EBUSY, because the reason
why it fails is that the module is being removed at that time.
Link: http://lkml.kernel.org/r/20130516114848.13508.97899.stgit@mhiramat-M0-7522
Cc: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Tom Zanussi <tom.zanussi@intel.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@redhat.com>
Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel/mutex.h')
0 files changed, 0 insertions, 0 deletions