mirror of
https://github.com/FEX-Emu/linux.git
synced 2024-12-28 12:25:31 +00:00
IB/ehca: Fix memory leak in error path of ehca_get_dma_mr()
Signed-off-by: Joachim Fenkes <fenkes@de.ibm.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
This commit is contained in:
parent
fbb9318be4
commit
3df78f81e0
@ -111,6 +111,7 @@ struct ib_mr *ehca_get_dma_mr(struct ib_pd *pd, int mr_access_flags)
|
||||
&e_maxmr->ib.ib_mr.lkey,
|
||||
&e_maxmr->ib.ib_mr.rkey);
|
||||
if (ret) {
|
||||
ehca_mr_delete(e_maxmr);
|
||||
ib_mr = ERR_PTR(ret);
|
||||
goto get_dma_mr_exit0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user