public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Taint kernel when we detect a corrupted slab.
@ 2012-09-18 15:05 Dave Jones
  2012-09-18 16:57 ` Christoph Lameter
  0 siblings, 1 reply; 6+ messages in thread
From: Dave Jones @ 2012-09-18 15:05 UTC (permalink / raw)
  To: Linux Kernel; +Cc: cl

It doesn't seem worth adding a new taint flag for this, so just re-use
the one from 'bad page'

Signed-off-by: Dave Jones <davej@redhat.com>

diff --git a/mm/slub.c b/mm/slub.c
index 2fdd96f..0c5009d 100644
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -568,6 +568,8 @@ static void slab_bug(struct kmem_cache *s, char *fmt, ...)
 	printk(KERN_ERR "BUG %s (%s): %s\n", s->name, print_tainted(), buf);
 	printk(KERN_ERR "----------------------------------------"
 			"-------------------------------------\n\n");
+
+	add_taint(TAINT_BAD_PAGE);
 }
 
 static void slab_fix(struct kmem_cache *s, char *fmt, ...)

^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-09-19  7:09 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-18 15:05 Taint kernel when we detect a corrupted slab Dave Jones
2012-09-18 16:57 ` Christoph Lameter
2012-09-18 19:27   ` David Rientjes
2012-09-18 19:54     ` Dave Jones
2012-09-18 20:19       ` David Rientjes
2012-09-19  7:09         ` Pekka Enberg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox