* [PATCH] nvme_fc: remove double put reference if admin connect fails
@ 2017-11-29 23:11 James Smart
2017-12-04 20:20 ` Christoph Hellwig
0 siblings, 1 reply; 2+ messages in thread
From: James Smart @ 2017-11-29 23:11 UTC (permalink / raw)
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: James Smart <james.smart at broadcom.com>
---
drivers/nvme/host/fc.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/nvme/host/fc.c b/drivers/nvme/host/fc.c
index 0a8af4daef89..794e66e4aa20 100644
--- a/drivers/nvme/host/fc.c
+++ b/drivers/nvme/host/fc.c
@@ -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);
--
2.13.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [PATCH] nvme_fc: remove double put reference if admin connect fails
2017-11-29 23:11 [PATCH] nvme_fc: remove double put reference if admin connect fails James Smart
@ 2017-12-04 20:20 ` Christoph Hellwig
0 siblings, 0 replies; 2+ messages in thread
From: Christoph Hellwig @ 2017-12-04 20:20 UTC (permalink / raw)
Thanks,
applied to nvme-4.15.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-12-04 20:20 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-11-29 23:11 [PATCH] nvme_fc: remove double put reference if admin connect fails James Smart
2017-12-04 20:20 ` Christoph Hellwig
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox