Commit eb06f43f authored by Andrey Ryabinin's avatar Andrey Ryabinin Committed by Linus Torvalds

kasan: always taint kernel on report

Currently we already taint the kernel in some cases.  E.g.  if we hit some
bug in slub memory we call object_err() which will taint the kernel with
TAINT_BAD_PAGE flag.  But for other kind of bugs kernel left untainted.

Always taint with TAINT_BAD_PAGE if kasan found some bug.  This is useful
for automated testing.
Signed-off-by: default avatarAndrey Ryabinin <>
Cc: Alexander Potapenko <>
Reviewed-by: default avatarDmitry Vyukov <>
Signed-off-by: default avatarAndrew Morton <>
Signed-off-by: default avatarLinus Torvalds <>
parent 89d3c87e
......@@ -238,6 +238,7 @@ static void kasan_report_error(struct kasan_access_info *info)
spin_unlock_irqrestore(&report_lock, flags);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment