nvme: apple: fix device reference counting
[ Upstream commit b9ecbfa4 ] Drivers must call nvme_uninit_ctrl after a successful nvme_init_ctrl. Split the allocation side out to make the error handling boundary easier to navigate. The apple driver had been doing this wrong, leaking the controller device memory on a tagset failure. Reviewed-by:Christoph Hellwig <hch@lst.de> Reviewed-by:
Chaitanya Kulkarni <kch@nvidia.com> Signed-off-by:
Keith Busch <kbusch@kernel.org> [ Resolve minor conflicts ] Signed-off-by:
Bin Lan <bin.lan.cn@windriver.com> Signed-off-by:
Sasha Levin <sashal@kernel.org>
Loading
Please sign in to comment