projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
fd62678
)
nvme: clear the request_queue pointers on failure in nvme_alloc_io_tag_set
author
Maurizio Lombardi
<mlombard@redhat.com>
Tue, 31 Jan 2023 16:38:42 +0000
(17:38 +0100)
committer
Christoph Hellwig
<hch@lst.de>
Wed, 1 Feb 2023 13:18:46 +0000
(14:18 +0100)
In nvme_alloc_io_tag_set(), the connect_q pointer should be set to NULL
in case of error to avoid potential invalid pointer dereferences.
Signed-off-by: Maurizio Lombardi <mlombard@redhat.com>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
drivers/nvme/host/core.c
patch
|
blob
|
history
diff --git
a/drivers/nvme/host/core.c
b/drivers/nvme/host/core.c
index 1c333ce64bd441c2b72c909b7c21f79664de65fd..c777f56a9e74f5da6e5edf5cb091e3178704039b 100644
(file)
--- a/
drivers/nvme/host/core.c
+++ b/
drivers/nvme/host/core.c
@@
-4956,6
+4956,7
@@
int nvme_alloc_io_tag_set(struct nvme_ctrl *ctrl, struct blk_mq_tag_set *set,
out_free_tag_set:
blk_mq_free_tag_set(set);
+ ctrl->connect_q = NULL;
return ret;
}
EXPORT_SYMBOL_GPL(nvme_alloc_io_tag_set);