brelse() is missed in ldiskfs_xattr_delete_inode(), this
defect is introduced by the ldiskfs large EA patch.
Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: Icfe6015ce9d518b11ec448fe32673ef76ebf4c85
new_offs = le16_to_cpu(last->e_value_offs) +
value_offs_shift;
BUG_ON(new_offs + le32_to_cpu(last->e_value_size)
new_offs = le16_to_cpu(last->e_value_offs) +
value_offs_shift;
BUG_ON(new_offs + le32_to_cpu(last->e_value_size)
-@@ -1356,20 +1667,89 @@ cleanup:
+@@ -1356,20 +1667,92 @@ cleanup:
+ if (entry->e_value_inum == 0)
+ continue;
+ if (ext4_expand_ino_array(lea_ino_array,
+ if (entry->e_value_inum == 0)
+ continue;
+ if (ext4_expand_ino_array(lea_ino_array,
-+ entry->e_value_inum) != 0)
++ entry->e_value_inum) != 0) {
++ brelse(iloc.bh);
+ entry->e_value_inum = 0;
+ }
+ entry->e_value_inum = 0;
+ }
+delete_external_ea:
if (!EXT4_I(inode)->i_file_acl)
+delete_external_ea:
if (!EXT4_I(inode)->i_file_acl)
new_offs = le16_to_cpu(last->e_value_offs) +
value_offs_shift;
BUG_ON(new_offs + le32_to_cpu(last->e_value_size)
new_offs = le16_to_cpu(last->e_value_offs) +
value_offs_shift;
BUG_ON(new_offs + le32_to_cpu(last->e_value_size)
-@@ -1359,20 +1673,89 @@ cleanup:
+@@ -1359,20 +1673,92 @@ cleanup:
+ if (entry->e_value_inum == 0)
+ continue;
+ if (ext4_expand_ino_array(lea_ino_array,
+ if (entry->e_value_inum == 0)
+ continue;
+ if (ext4_expand_ino_array(lea_ino_array,
-+ entry->e_value_inum) != 0)
++ entry->e_value_inum) != 0) {
++ brelse(iloc.bh);
+ entry->e_value_inum = 0;
+ }
+ entry->e_value_inum = 0;
+ }
+delete_external_ea:
if (!EXT4_I(inode)->i_file_acl)
+delete_external_ea:
if (!EXT4_I(inode)->i_file_acl)