Messages in this thread | | | Date | Fri, 24 Jan 2020 10:28:30 -0500 | From | Steven Rostedt <> | Subject | Re: WARNING in tracing_func_proto |
| |
On Fri, 24 Jan 2020 11:44:13 +0100 Dmitry Vyukov <dvyukov@google.com> wrote:
> FWIW this is invalid use of WARN macros: > https://elixir.bootlin.com/linux/v5.5-rc7/source/include/asm-generic/bug.h#L72 > This should be replaced with pr_err (if really necessary, kernel does > not generally spew stacks on every ENOMEM/EINVAL).
That message was added in 2018. The WARN macro in question here, was added in 2011. Thus, this would be more of a clean up fix.
> > There are no _lots_ such wrong uses of WARN in the kernel. There were > some, all get fixed over time, we are still discovering long tail, but > it's like one per months at most. Note: syzbot reports each and every > WARNING. If there were lots, you would notice :)
Hmm, I haven't looked, but are all these correct usage?
$ git grep WARN_ON HEAD | wc -l 15384
I also checked the number of WARN_ON when that WARN_ON was added:
$ git grep WARN_ON 07d777fe8c3985bc83428c2866713c2d1b3d4129 | wc -l 4730
A lot more were added since then!
> > Sorting this out is critical for just any kernel testing. Otherwise no > testing system will be able to say if a test triggers something bad in > kernel or not. > > FWIW there are no local trees for syzbot. It only tests public trees > as is. Doing otherwise would not work/scale as a process.
Anyway, I'll happily take a patch converting that WARN_ON macro to a pr_err() print.
-- Steve
| |