Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4596e752 authored by James Smart's avatar James Smart Committed by Christoph Hellwig
Browse files

nvme-fc: remove double put reference if admin connect fails



There are two put references in the failure case of initial
create_association. The first put actually frees the controller, thus the
second put references freed memory.

Remove the unnecessary 2nd put.

Signed-off-by: default avatarJames Smart <james.smart@broadcom.com>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent b224f613
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -3221,7 +3221,6 @@ nvme_fc_init_ctrl(struct device *dev, struct nvmf_ctrl_options *opts,

		/* initiate nvme ctrl ref counting teardown */
		nvme_uninit_ctrl(&ctrl->ctrl);
		nvme_put_ctrl(&ctrl->ctrl);

		/* Remove core ctrl ref. */
		nvme_put_ctrl(&ctrl->ctrl);