aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nilfs2/mdt.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/nilfs2/mdt.c')
-rw-r--r--fs/nilfs2/mdt.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/fs/nilfs2/mdt.c b/fs/nilfs2/mdt.c
index 1125f40233ff..f6982b9153d5 100644
--- a/fs/nilfs2/mdt.c
+++ b/fs/nilfs2/mdt.c
@@ -110,7 +110,7 @@ static int nilfs_mdt_create_block(struct inode *inode, unsigned long block,
110 110
111 failed_bh: 111 failed_bh:
112 unlock_page(bh->b_page); 112 unlock_page(bh->b_page);
113 page_cache_release(bh->b_page); 113 put_page(bh->b_page);
114 brelse(bh); 114 brelse(bh);
115 115
116 failed_unlock: 116 failed_unlock:
@@ -170,7 +170,7 @@ nilfs_mdt_submit_block(struct inode *inode, unsigned long blkoff,
170 170
171 failed_bh: 171 failed_bh:
172 unlock_page(bh->b_page); 172 unlock_page(bh->b_page);
173 page_cache_release(bh->b_page); 173 put_page(bh->b_page);
174 brelse(bh); 174 brelse(bh);
175 failed: 175 failed:
176 return ret; 176 return ret;
@@ -363,7 +363,7 @@ int nilfs_mdt_delete_block(struct inode *inode, unsigned long block)
363int nilfs_mdt_forget_block(struct inode *inode, unsigned long block) 363int nilfs_mdt_forget_block(struct inode *inode, unsigned long block)
364{ 364{
365 pgoff_t index = (pgoff_t)block >> 365 pgoff_t index = (pgoff_t)block >>
366 (PAGE_CACHE_SHIFT - inode->i_blkbits); 366 (PAGE_SHIFT - inode->i_blkbits);
367 struct page *page; 367 struct page *page;
368 unsigned long first_block; 368 unsigned long first_block;
369 int ret = 0; 369 int ret = 0;
@@ -376,7 +376,7 @@ int nilfs_mdt_forget_block(struct inode *inode, unsigned long block)
376 wait_on_page_writeback(page); 376 wait_on_page_writeback(page);
377 377
378 first_block = (unsigned long)index << 378 first_block = (unsigned long)index <<
379 (PAGE_CACHE_SHIFT - inode->i_blkbits); 379 (PAGE_SHIFT - inode->i_blkbits);
380 if (page_has_buffers(page)) { 380 if (page_has_buffers(page)) {
381 struct buffer_head *bh; 381 struct buffer_head *bh;
382 382
@@ -385,7 +385,7 @@ int nilfs_mdt_forget_block(struct inode *inode, unsigned long block)
385 } 385 }
386 still_dirty = PageDirty(page); 386 still_dirty = PageDirty(page);
387 unlock_page(page); 387 unlock_page(page);
388 page_cache_release(page); 388 put_page(page);
389 389
390 if (still_dirty || 390 if (still_dirty ||
391 invalidate_inode_pages2_range(inode->i_mapping, index, index) != 0) 391 invalidate_inode_pages2_range(inode->i_mapping, index, index) != 0)
@@ -578,7 +578,7 @@ int nilfs_mdt_freeze_buffer(struct inode *inode, struct buffer_head *bh)
578 } 578 }
579 579
580 unlock_page(page); 580 unlock_page(page);
581 page_cache_release(page); 581 put_page(page);
582 return 0; 582 return 0;
583} 583}
584 584
@@ -597,7 +597,7 @@ nilfs_mdt_get_frozen_buffer(struct inode *inode, struct buffer_head *bh)
597 bh_frozen = nilfs_page_get_nth_block(page, n); 597 bh_frozen = nilfs_page_get_nth_block(page, n);
598 } 598 }
599 unlock_page(page); 599 unlock_page(page);
600 page_cache_release(page); 600 put_page(page);
601 } 601 }
602 return bh_frozen; 602 return bh_frozen;
603} 603}