nvme-pci: simplify __nvme_submit_cmd
authorChristoph Hellwig <hch@lst.de>
Sat, 26 May 2018 11:45:55 +0000 (13:45 +0200)
committerChristoph Hellwig <hch@lst.de>
Wed, 30 May 2018 06:04:26 +0000 (08:04 +0200)
commit90ea5ca45c1fa09bec83ea106b9947170a00edb8
treed5b484a72667e1bd4dfc8dcf651ddf4aed32ce03
parentb9cac43c2c4aab221ee0bac72bd6b9f8bf00a223
nvme-pci: simplify __nvme_submit_cmd

With recent CQ handling improvements we can now move the locking into
__nvme_submit_cmd.  Also remove the local tail variable to make the code
more obvious, remove the __ prefix in the name, and fix the comments
describing the function.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Jens Axboe <axboe@kernel.dk>
Reviewed-by: Max Gurtovoy <maxg@mellanox.com>
drivers/nvme/host/pci.c