Skip to content

Commit

Permalink
BUG_ON() Conversion in mm/vmalloc.c
Browse files Browse the repository at this point in the history
this changes if() BUG(); constructs to BUG_ON() which is
cleaner, contains unlikely() and can better optimized away.

Signed-off-by: Eric Sesterhenn <[email protected]>
Signed-off-by: Adrian Bunk <[email protected]>
  • Loading branch information
SesterhennEric authored and AdrianBunk committed Mar 31, 2006
1 parent e74ca2b commit 5aae277
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions mm/vmalloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -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]);
}

Expand Down

0 comments on commit 5aae277

Please sign in to comment.