From e74ca2b49b8a38e9ba0bc039a00498c21140f1d6 Mon Sep 17 00:00:00 2001 From: Eric Sesterhenn Date: Sat, 1 Apr 2006 01:25:12 +0200 Subject: [PATCH] BUG_ON() Conversion in mm/swap_state.c this changes if() BUG(); constructs to BUG_ON() which is cleaner, contains unlikely() and can better optimized away. Signed-off-by: Eric Sesterhenn Signed-off-by: Adrian Bunk --- mm/swap_state.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/mm/swap_state.c b/mm/swap_state.c index d7af296833..e0e1583f32 100644 --- a/mm/swap_state.c +++ b/mm/swap_state.c @@ -148,8 +148,7 @@ int add_to_swap(struct page * page, gfp_t gfp_mask) swp_entry_t entry; int err; - if (!PageLocked(page)) - BUG(); + BUG_ON(!PageLocked(page)); for (;;) { entry = get_swap_page(); -- 2.39.5