Commit 5a5754a4 authored by Keith Busch's avatar Keith Busch Committed by Christoph Hellwig

nvme-pci: flush initial scan_work for async probe

The nvme device may have a namespace with the root partition, so make
sure we've completed scanning before returning from the async probe.

Fixes: eac3ef26 ("nvme-pci: split the initial probe from the rest path")
Reported-by: default avatarKlaus Jensen <its@irrelevant.dk>
Signed-off-by: default avatarKeith Busch <kbusch@kernel.org>
Tested-by: default avatarVille Syrjälä <ville.syrjala@linux.intel.com>
Tested-by: default avatarKlaus Jensen <k.jensen@samsung.com>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent 98e35280
......@@ -3102,6 +3102,7 @@ static int nvme_probe(struct pci_dev *pdev, const struct pci_device_id *id)
nvme_start_ctrl(&dev->ctrl);
nvme_put_ctrl(&dev->ctrl);
flush_work(&dev->ctrl.scan_work);
return 0;
out_disable:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment