lkdtm: Split WARNING into separate tests
authorKees Cook <keescook@chromium.org>
Mon, 19 Aug 2019 17:24:52 +0000 (10:24 -0700)
committerKees Cook <keescook@chromium.org>
Mon, 19 Aug 2019 18:13:21 +0000 (11:13 -0700)
commit1ee170ea3f0dcf3a4b34f7e7c36559e84bb0d3d6
tree103a354bd200370888a73fe1ebdb2e1ad517f735
parentb0eb93cfd516201ccf0e4d36e226cfe1b16cc1fe
lkdtm: Split WARNING into separate tests

There are three paths through the kernel code exception logging:

- BUG (no configurable printk message)
- WARN_ON (no configurable printk message)
- WARN (configurable printk message)

LKDTM was not testing WARN_ON(). This is needed to evaluate the placement
of the "cut here" line, which needs special handling in each of the
three exceptions (and between architectures that implement instruction
exceptions to implement the code exceptions).

Signed-off-by: Kees Cook <keescook@chromium.org>
drivers/misc/lkdtm/bugs.c
drivers/misc/lkdtm/core.c
drivers/misc/lkdtm/lkdtm.h