BUG_ON() Conversion in mm/vmalloc.c
authorEric Sesterhenn <snakebyte@gmx.de>
Fri, 31 Mar 2006 23:26:09 +0000 (01:26 +0200)
committerAdrian Bunk <bunk@stusta.de>
Fri, 31 Mar 2006 23:26:09 +0000 (01:26 +0200)
this changes if() BUG(); constructs to BUG_ON() which is
cleaner, contains unlikely() and can better optimized away.

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
mm/vmalloc.c

index 729eb3eec75fd7043b8b8a74e6b748b9390b0f6d..c0504f1e34ebdbd2003ba8aaa63287f366b100cb 100644 (file)
@@ -321,8 +321,7 @@ void __vunmap(void *addr, int deallocate_pages)
                int i;
 
                for (i = 0; i < area->nr_pages; i++) {
-                       if (unlikely(!area->pages[i]))
-                               BUG();
+                       BUG_ON(!area->pages[i]);
                        __free_page(area->pages[i]);
                }