]> git.baikalelectronics.ru Git - kernel.git/commit
nvme: refactor nvme_validate_ns
authorChristoph Hellwig <hch@lst.de>
Mon, 28 Sep 2020 11:59:06 +0000 (13:59 +0200)
committerChristoph Hellwig <hch@lst.de>
Wed, 7 Oct 2020 05:56:19 +0000 (07:56 +0200)
commit870f31c340520f54bd2f9c407422fb76054a835c
treefb17fb19372991c1f4ab38cece7814c312950eac
parent92c3a543efcb9e3a5913de8897c3947e914fee9e
nvme: refactor nvme_validate_ns

Move the logic to revalidate the block_device size or remove the
namespace from the caller into nvme_validate_ns.  This removes
the return value and thus the status code translation.  Additionally
it also catches non-permanent errors from nvme_update_ns_info using
the existing logic.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Keith Busch <kbusch@kernel.org>
Reviewed-by: Damien Le Moal <damien.lemoal@wdc.com>
drivers/nvme/host/core.c