diff options
Diffstat (limited to 'fs/buffer.c')
-rw-r--r-- | fs/buffer.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/fs/buffer.c b/fs/buffer.c index a507b58550f1..d597758dd129 100644 --- a/fs/buffer.c +++ b/fs/buffer.c | |||
@@ -798,8 +798,7 @@ void mark_buffer_dirty_inode(struct buffer_head *bh, struct inode *inode) | |||
798 | if (!mapping->assoc_mapping) { | 798 | if (!mapping->assoc_mapping) { |
799 | mapping->assoc_mapping = buffer_mapping; | 799 | mapping->assoc_mapping = buffer_mapping; |
800 | } else { | 800 | } else { |
801 | if (mapping->assoc_mapping != buffer_mapping) | 801 | BUG_ON(mapping->assoc_mapping != buffer_mapping); |
802 | BUG(); | ||
803 | } | 802 | } |
804 | if (list_empty(&bh->b_assoc_buffers)) { | 803 | if (list_empty(&bh->b_assoc_buffers)) { |
805 | spin_lock(&buffer_mapping->private_lock); | 804 | spin_lock(&buffer_mapping->private_lock); |
@@ -1116,8 +1115,7 @@ grow_dev_page(struct block_device *bdev, sector_t block, | |||
1116 | if (!page) | 1115 | if (!page) |
1117 | return NULL; | 1116 | return NULL; |
1118 | 1117 | ||
1119 | if (!PageLocked(page)) | 1118 | BUG_ON(!PageLocked(page)); |
1120 | BUG(); | ||
1121 | 1119 | ||
1122 | if (page_has_buffers(page)) { | 1120 | if (page_has_buffers(page)) { |
1123 | bh = page_buffers(page); | 1121 | bh = page_buffers(page); |
@@ -1524,8 +1522,7 @@ void set_bh_page(struct buffer_head *bh, | |||
1524 | struct page *page, unsigned long offset) | 1522 | struct page *page, unsigned long offset) |
1525 | { | 1523 | { |
1526 | bh->b_page = page; | 1524 | bh->b_page = page; |
1527 | if (offset >= PAGE_SIZE) | 1525 | BUG_ON(offset >= PAGE_SIZE); |
1528 | BUG(); | ||
1529 | if (PageHighMem(page)) | 1526 | if (PageHighMem(page)) |
1530 | /* | 1527 | /* |
1531 | * This catches illegal uses and preserves the offset: | 1528 | * This catches illegal uses and preserves the offset: |