The error branch for ext4_xattr_inode_update_ref forget to release the refcount for iloc.bh. Find this when review code.
Unified · Split
| @@ -1037,6 +1037,7 @@ static int ext4_xattr_inode_update_ref(handle_t *handle, struct inode *ea_inode, · 1036 unmodified lines | |||
| 1037 | ext4_error_inode(ea_inode, __func__, __LINE__, 0, | 1037 | ext4_error_inode(ea_inode, __func__, __LINE__, 0, |
| 1038 | "EA inode %lu ref wraparound: ref_count=%lld ref_change=%d", | 1038 | "EA inode %lu ref wraparound: ref_count=%lld ref_change=%d", |
| 1039 | ea_inode->i_ino, ref_count, ref_change); | 1039 | ea_inode->i_ino, ref_count, ref_change); |
| 1040 | brelse(iloc.bh); | ||
| 1040 | ret = -EFSCORRUPTED; | 1041 | ret = -EFSCORRUPTED; |
| 1041 | goto out; | 1042 | goto out; |
| 1042 | } | 1043 | } |