mirror of
https://github.com/torvalds/linux
synced 2024-11-02 18:48:59 +00:00
Merge branch 'nvme-5.7' of git://git.infradead.org/nvme into block-5.7
Pull NVMe fix from Christoph. * 'nvme-5.7' of git://git.infradead.org/nvme: nvme: prevent double free in nvme_alloc_ns() error handling
This commit is contained in:
commit
47ed39e062
1 changed files with 2 additions and 0 deletions
|
@ -3642,6 +3642,8 @@ static void nvme_alloc_ns(struct nvme_ctrl *ctrl, unsigned nsid)
|
|||
|
||||
return;
|
||||
out_put_disk:
|
||||
/* prevent double queue cleanup */
|
||||
ns->disk->queue = NULL;
|
||||
put_disk(ns->disk);
|
||||
out_unlink_ns:
|
||||
mutex_lock(&ctrl->subsys->lock);
|
||||
|
|
Loading…
Reference in a new issue