Add taint flag outputting to slab debug paths.
When we get corruption reports, it's useful to see if the kernel was tainted, to rule out problems we can't do anything about.
Signed-off-by Dave Jones <[email protected]>
mm/slab.c +4 -4
@@ -1803,8 +1803,8 @@ static void check_poison_obj(struct kmem_cache *cachep, void *objp)/* Print header */ if (lines ==0 ) {printk (KERN_ERR -"Slab corruption: %s start=%p, len=%d\n" , - cachep->name, realobj, size); +"Slab corruption (%s): %s start=%p, len=%d\n" , +print_tainted (), cachep->name, realobj, size);print_objinfo (cachep, objp,0 ); }/* Hexdump the affected line */
@@ -2902,8 +2902,8 @@ static void check_slabp(struct kmem_cache *cachep, struct slab *slabp)if (entries != cachep->num - slabp->inuse) { bad:printk (KERN_ERR "slab: Internal list corruption detected in " -"cache '%s'(%d), slabp %p(%d). Hexdump:\n" , - cachep->name, cachep->num, slabp, slabp->inuse); +"cache '%s'(%d), slabp %p(%d). Tainted(%s). Hexdump:\n" , + cachep->name, cachep->num, slabp, slabp->inuse,print_tainted ());for (i =0 ; i <sizeof (*slabp) + cachep->num *sizeof (kmem_bufctl_t); i++) {
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>