]> git.baikalelectronics.ru Git - kernel.git/commit
nvmet: add a clear_ids attribute for passthru targets
authorAlan Adamson <alan.adamson@oracle.com>
Mon, 27 Jun 2022 23:25:43 +0000 (16:25 -0700)
committerChristoph Hellwig <hch@lst.de>
Thu, 30 Jun 2022 06:23:24 +0000 (08:23 +0200)
commite04787ef6bbd690c33067fdda0ae9df394f781fc
tree9e080dd043eff39d3715d54f79cddaae7e95c879
parenta77bf1745aa76971ee81f774ee535b7cf342a474
nvmet: add a clear_ids attribute for passthru targets

If the clear_ids attribute is set to true, the EUI/GUID/UUID is cleared
for the passthru target.  By default, loop targets will set clear_ids to
true.

This resolves an issue where a connect to a passthru target fails when
using a trtype of 'loop' because EUI/GUID/UUID is not unique.

Fixes: cefdfcdbff7f ("nvme: check that EUI/GUID/UUID are globally unique")
Signed-off-by: Alan Adamson <alan.adamson@oracle.com>
Reviewed-by: Keith Busch <kbusch@kernel.org>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
drivers/nvme/target/configfs.c
drivers/nvme/target/core.c
drivers/nvme/target/nvmet.h
drivers/nvme/target/passthru.c