mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-05 19:31:57 -04:00
xfs: Add the missed xfs_perag_put() for xfs_ifree_cluster()
commit 8cc0072469723459dc6bd7beff81b2b3149f4cf4 upstream.
xfs_ifree_cluster() calls xfs_perag_get() at the beginning, but forgets to
call xfs_perag_put() in one failed path.
Add the missed function call to fix it.
Fixes: ce92464c180b ("xfs: make xfs_trans_get_buf return an error code")
Signed-off-by: Chuhong Yuan <hslester96@gmail.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Acked-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Chandan Babu R <chandan.babu@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
0802130a4d
commit
ad18f624e3
1 changed files with 3 additions and 1 deletions
|
|
@ -2592,8 +2592,10 @@ xfs_ifree_cluster(
|
|||
mp->m_bsize * igeo->blocks_per_cluster,
|
||||
XBF_UNMAPPED);
|
||||
|
||||
if (!bp)
|
||||
if (!bp) {
|
||||
xfs_perag_put(pag);
|
||||
return -ENOMEM;
|
||||
}
|
||||
|
||||
/*
|
||||
* This buffer may not have been correctly initialised as we
|
||||
|
|
|
|||
Loading…
Reference in a new issue