]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit
nvme: tighten up state check for namespace scanning
authorChristoph Hellwig <hch@lst.de>
Tue, 26 Apr 2016 11:51:58 +0000 (13:51 +0200)
committerJens Axboe <axboe@fb.com>
Mon, 2 May 2016 15:09:23 +0000 (09:09 -0600)
commit92911a55d42084cd285250c275d9f238783638c2
tree57a8e413100b35efae3fe64fcf1a752c9d36776c
parentbb8d261e088811ef2b564d745afcd1633428010a
nvme: tighten up state check for namespace scanning

We only should be scanning namespaces if the controller is live.  Currently
we call the function just before setting it live, so fix the code up to
move the call to nvme_queue_scan to just below the state change.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Acked-by Jon Derrick: <jonathan.derrick@intel.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
drivers/nvme/host/pci.c