lkml.org 
[lkml]   [2007]   [Apr]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: checkpatch, a patch checking script.
From
Date
Andrew Morton <akpm@linux-foundation.org> writes:

> box:/usr/src/25> ~/checkpatch.pl patches/slub-core.patch
> Checking patches/slub-core.patch: signoffs = 30
> Use WARN_ON & Recovery code rather than BUG() and BUG_ON()

The warning is bogus imho. How do you write recovery code for internal
broken code logic?

-Andi


> 1588:+ VM_BUG_ON(!irqs_disabled());
> 1834:+ BUG_ON(flags & ~(GFP_DMA | GFP_LEVEL_MASK));
> 2538:+ BUG_ON(kmalloc_caches->size < sizeof(struct kmem_cache_node));
> 2544:+ BUG_ON(!page);
> 2546:+ BUG_ON(!n);
> 2736:+ BUG_ON(err);
> 2762:+ BUG_ON(flags & SLUB_UNIMPLEMENTED);
> 2777:+ BUG_ON(flags & (SLAB_RED_ZONE | SLAB_POISON |
> 2779:+ BUG_ON(ctor || dtor);
> 3054:+ BUG_ON(index < 0);
> 3118:+ BUG_ON(!page);
> 3120:+ BUG_ON(!s);
> 4062:+ BUG_ON(!name);
> 4083:+ BUG_ON(p > name + ID_STR_LENGTH - 1);
> 4188:+ BUG_ON(err);
>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-04-28 11:53    [W:0.204 / U:0.048 seconds]
©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site