OSDN Git Service

nvme: Cleanup and rename nvme_block_nr()
authorDamien Le Moal <damien.lemoal@wdc.com>
Mon, 21 Oct 2019 03:40:03 +0000 (12:40 +0900)
committerJens Axboe <axboe@kernel.dk>
Mon, 4 Nov 2019 17:56:41 +0000 (10:56 -0700)
commit314d48dd224897e35ddcaf5a1d7d133b5adddeb7
treedbf7238ea8feb0078a99ec38094f4a1416ad8cdf
parent48c9e85b23464a7d1e3ebd70b79cc3a2d97d3222
nvme: Cleanup and rename nvme_block_nr()

Rename nvme_block_nr() to nvme_sect_to_lba() and use SECTOR_SHIFT
instead of its hard coded value 9. Also add a comment to decribe this
helper.

Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com>
Signed-off-by: Keith Busch <kbusch@kernel.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/nvme/host/core.c
drivers/nvme/host/nvme.h