]> www.infradead.org Git - users/jedix/linux-maple.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)
committerChuck Anderson <chuck.anderson@oracle.com>
Thu, 1 Jun 2017 20:41:20 +0000 (13:41 -0700)
commit9768168dabd66878510d756cfc464134ef226472
tree7aaa4ac6b93126525cd1859651303d9ab1c10a6f
parent0cfc216a1d27fb7c393079e15d6646d12e2f5e17
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>
(cherry picked from commit 92911a55d42084cd285250c275d9f238783638c2)

Orabug: 25130845

Signed-off-by: Ashok Vairavan <ashok.vairavan@oracle.com>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/nvme/host/pci.c