Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1522070
| From | Alexei Starovoitov <alexei.starovoitov@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] tracing: ignore FTRACE_FL_DISABLED while walking dyn_ftrace records |
| Date | 2016-11-14 21:40 +0100 |
| Message-ID | <sDwcN-3pr-11@gated-at.bofh.it> (permalink) |
| References | <sB1mN-1rD-9@gated-at.bofh.it> <sDv74-2Ll-7@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Mon, Nov 14, 2016 at 02:24:28PM -0500, Steven Rostedt wrote: > On Mon, 7 Nov 2016 15:14:20 -0800 > Alexei Starovoitov <ast@fb.com> wrote: > > > ftrace_shutdown() checks for sanity of ftrace records > > and if dyn_ftrace->flags is not zero, it will warn. > > It can happen that 'flags' are set to FTRACE_FL_DISABLED at this point, > > since some module was loaded, but before ftrace_module_enable() > > cleared the flags for this module. > > > > In other words the module.c is doing: > > ftrace_module_init(mod); // calls ftrace_update_code() that sets flags=FTRACE_FL_DISABLED > > ... // here ftrace_shutdown() is called that warns, since > > err = prepare_coming_module(mod); // didn't have a chance to clear FTRACE_FL_DISABLED > > > > Fix it by ignoring disabled records. > > It's similar to what __ftrace_hash_rec_update() is already doing. > > > > Alexei, > > Do you have a clear reproducer of this bug? Nope. No reproducer. It's very rare. Only stack trace that I posted earlier. Since it kills ftrace everything that depends on it later spews a ton of other warnings. So it's an important fix.
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
Re: [PATCH] tracing: ignore FTRACE_FL_DISABLED while walking dyn_ftrace records Steven Rostedt <rostedt@goodmis.org> - 2016-11-14 20:30 +0100 Re: [PATCH] tracing: ignore FTRACE_FL_DISABLED while walking dyn_ftrace records Alexei Starovoitov <alexei.starovoitov@gmail.com> - 2016-11-14 21:40 +0100
csiph-web