mirror of
https://github.com/adulau/aha.git
synced 2024-12-28 03:36:19 +00:00
BUG_ON() Conversion in fs/sysv/
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>
This commit is contained in:
parent
b7542f8c7e
commit
d6735bfcc9
1 changed files with 2 additions and 4 deletions
|
@ -253,8 +253,7 @@ int sysv_delete_entry(struct sysv_dir_entry *de, struct page *page)
|
|||
|
||||
lock_page(page);
|
||||
err = mapping->a_ops->prepare_write(NULL, page, from, to);
|
||||
if (err)
|
||||
BUG();
|
||||
BUG_ON(err);
|
||||
de->inode = 0;
|
||||
err = dir_commit_chunk(page, from, to);
|
||||
dir_put_page(page);
|
||||
|
@ -353,8 +352,7 @@ void sysv_set_link(struct sysv_dir_entry *de, struct page *page,
|
|||
|
||||
lock_page(page);
|
||||
err = page->mapping->a_ops->prepare_write(NULL, page, from, to);
|
||||
if (err)
|
||||
BUG();
|
||||
BUG_ON(err);
|
||||
de->inode = cpu_to_fs16(SYSV_SB(inode->i_sb), inode->i_ino);
|
||||
err = dir_commit_chunk(page, from, to);
|
||||
dir_put_page(page);
|
||||
|
|
Loading…
Reference in a new issue