On Sat, 3 Sep 2016 13:30:12 -0400, Eric Garver wrote:
> Would a BUG_ON(!(encap && in_encap)) be better?

Please don't crash the kernel for something that could very well
continue without problems. Use WARN_ON at most.

And if you go that way, WARN_ON_ONCE or rate limiting seems to be even
more appropriate, because if this triggers, it's quite possible it will
trigger repeatedly and the resulting log flood would practically make
the machine useless anyway.

Thanks,

 Jiri

Reply via email to