RDMA/hns: fix memory leak in hns_roce_alloc_mr()
mainline inclusion from mainline-v6.2-rc1 commit a115aa00 category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I6RP11 CVE: NA Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=a115aa00b18f7b8982b8f458149632caf64a862a ---------------------------------------------------------------------- When hns_roce_mr_enable() failed in hns_roce_alloc_mr(), mr_key is not released. Compiled test only. Fixes: 9b2cf76c ("RDMA/hns: Optimize PBL buffer allocation process") Signed-off-by:Zhengchao Shao <shaozhengchao@huawei.com> Link: https://lore.kernel.org/r/20221119070834.48502-1-shaozhengchao@huawei.com Signed-off-by:
Leon Romanovsky <leon@kernel.org> Signed-off-by:
Zhou Juan <nnuzj07170227@163.com>
Loading
Please sign in to comment