diff options
Diffstat (limited to 'fs/nilfs2/alloc.c')
-rw-r--r-- | fs/nilfs2/alloc.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/fs/nilfs2/alloc.c b/fs/nilfs2/alloc.c index d7fd696e595c..0a0a66d98cce 100644 --- a/fs/nilfs2/alloc.c +++ b/fs/nilfs2/alloc.c | |||
@@ -521,8 +521,8 @@ void nilfs_palloc_commit_free_entry(struct inode *inode, | |||
521 | group_offset, bitmap)) | 521 | group_offset, bitmap)) |
522 | printk(KERN_WARNING "%s: entry number %llu already freed\n", | 522 | printk(KERN_WARNING "%s: entry number %llu already freed\n", |
523 | __func__, (unsigned long long)req->pr_entry_nr); | 523 | __func__, (unsigned long long)req->pr_entry_nr); |
524 | 524 | else | |
525 | nilfs_palloc_group_desc_add_entries(inode, group, desc, 1); | 525 | nilfs_palloc_group_desc_add_entries(inode, group, desc, 1); |
526 | 526 | ||
527 | kunmap(req->pr_bitmap_bh->b_page); | 527 | kunmap(req->pr_bitmap_bh->b_page); |
528 | kunmap(req->pr_desc_bh->b_page); | 528 | kunmap(req->pr_desc_bh->b_page); |
@@ -558,8 +558,8 @@ void nilfs_palloc_abort_alloc_entry(struct inode *inode, | |||
558 | group_offset, bitmap)) | 558 | group_offset, bitmap)) |
559 | printk(KERN_WARNING "%s: entry number %llu already freed\n", | 559 | printk(KERN_WARNING "%s: entry number %llu already freed\n", |
560 | __func__, (unsigned long long)req->pr_entry_nr); | 560 | __func__, (unsigned long long)req->pr_entry_nr); |
561 | 561 | else | |
562 | nilfs_palloc_group_desc_add_entries(inode, group, desc, 1); | 562 | nilfs_palloc_group_desc_add_entries(inode, group, desc, 1); |
563 | 563 | ||
564 | kunmap(req->pr_bitmap_bh->b_page); | 564 | kunmap(req->pr_bitmap_bh->b_page); |
565 | kunmap(req->pr_desc_bh->b_page); | 565 | kunmap(req->pr_desc_bh->b_page); |
@@ -665,7 +665,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems) | |||
665 | for (j = i, n = 0; | 665 | for (j = i, n = 0; |
666 | (j < nitems) && nilfs_palloc_group_is_in(inode, group, | 666 | (j < nitems) && nilfs_palloc_group_is_in(inode, group, |
667 | entry_nrs[j]); | 667 | entry_nrs[j]); |
668 | j++, n++) { | 668 | j++) { |
669 | nilfs_palloc_group(inode, entry_nrs[j], &group_offset); | 669 | nilfs_palloc_group(inode, entry_nrs[j], &group_offset); |
670 | if (!nilfs_clear_bit_atomic( | 670 | if (!nilfs_clear_bit_atomic( |
671 | nilfs_mdt_bgl_lock(inode, group), | 671 | nilfs_mdt_bgl_lock(inode, group), |
@@ -674,6 +674,8 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems) | |||
674 | "%s: entry number %llu already freed\n", | 674 | "%s: entry number %llu already freed\n", |
675 | __func__, | 675 | __func__, |
676 | (unsigned long long)entry_nrs[j]); | 676 | (unsigned long long)entry_nrs[j]); |
677 | } else { | ||
678 | n++; | ||
677 | } | 679 | } |
678 | } | 680 | } |
679 | nilfs_palloc_group_desc_add_entries(inode, group, desc, n); | 681 | nilfs_palloc_group_desc_add_entries(inode, group, desc, n); |