Messages in this thread | | | Date | Wed, 2 May 2012 09:18:58 +1000 | Subject | Re: [RFC] vmalloc: add warning in __vmalloc | From | Nick Piggin <> |
| |
On 2 May 2012 06:22, David Rientjes <rientjes@google.com> wrote: > On Tue, 1 May 2012, Nick Piggin wrote: > >> > I disagree with this approach since it's going to violently spam an >> > innocent kernel user's log with no ratelimiting and for a situation that >> > actually may not be problematic. >> >> With WARN_ON_ONCE, it should be good. >> > > To catch a single instance of this per-boot, sure. I've never seen us add > WARN_ON_ONCE()'s where we have concrete examples of kernel code that will > trigger it, though. Not sure why spamming the kernel log and getting > users to think something is wrong and report the bug when it's possible to > audit the code and make a report to the subsystem maintainer.
Because it needs to be an ongoing thing, which is caught as soon as the developer writes some code, rather than continually audited for and fixed up after the fact. There is not a good way to enforce this at compile time.
The existing callers do need to be fixed too, of course. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |