commit | 9c980795ccd77e8abec33dd6fe28dfe1c4083e65 | [log] [tgz] |
---|---|---|
author | Wu Bo <wubo40@huawei.com> | Wed May 19 13:01:10 2021 +0800 |
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | Wed May 26 12:06:48 2021 +0200 |
tree | ab09e972d2c5cb2273fa9e4682e46a869ede1a1c | |
parent | 4720f29acb3fe67aa8aa71e6b675b079d193aaeb [diff] |
nvme-loop: fix memory leak in nvme_loop_create_ctrl() [ Upstream commit 03504e3b54cc8118cc26c064e60a0b00c2308708 ] When creating loop ctrl in nvme_loop_create_ctrl(), if nvme_init_ctrl() fails, the loop ctrl should be freed before jumping to the "out" label. Fixes: 3a85a5de29ea ("nvme-loop: add a NVMe loopback host driver") Signed-off-by: Wu Bo <wubo40@huawei.com> Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Sasha Levin <sashal@kernel.org>