ext4: fix miss release buffer head in ext4_fc_write_inode
authorYe Bin <yebin10@huawei.com>
Wed, 14 Sep 2022 10:08:59 +0000 (18:08 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 26 Oct 2022 10:34:29 +0000 (12:34 +0200)
commitef1607c99136cabdcdad806f7e6d491e259f436d
treecfbaa69bf8334f480acac09a72c8a89b1ad75877
parentd29fa1ab4e6261f8dae6ba5b0364c3c9ae849342
ext4: fix miss release buffer head in ext4_fc_write_inode

commit ccbf8eeb39f2ff00b54726a2b20b35d788c4ecb5 upstream.

In 'ext4_fc_write_inode' function first call 'ext4_get_inode_loc' get 'iloc',
after use it miss release 'iloc.bh'.
So just release 'iloc.bh' before 'ext4_fc_write_inode' return.

Cc: stable@kernel.org
Signed-off-by: Ye Bin <yebin10@huawei.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Link: https://lore.kernel.org/r/20220914100859.1415196-1-yebin10@huawei.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/ext4/fast_commit.c