]> www.infradead.org Git - users/sagi/nvme-cli.git/commit
nvme-discover: lookup existing persistent controllers
authorHannes Reinecke <hare@suse.de>
Thu, 25 Feb 2021 16:12:20 +0000 (17:12 +0100)
committerMartin Wilck <mwilck@suse.com>
Tue, 30 Mar 2021 13:13:56 +0000 (15:13 +0200)
commit14d0e0f7e0c1b420da65783881c064e49ac7d6d7
treee203d3f6bf383b8c5308097118b61c437ae5d21f
parent81f54310e74f0a82c25a6f8a21316c30f1801299
nvme-discover: lookup existing persistent controllers

If persistent controller connections are present they should be
preferred even if no --device option is given on the commandline.

To avoid selecting a temporary non-persistent controller the
'kato' attribute is checked; any controller for which the
attribute is '0' will be skipped. This logic is not applied on
older kernels that don't support the 'kato' attribute. On these
kernels, we just have to assume that the encountered discovery
controller is persistent.

Signed-off-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Martin Wilck <mwilck@suse.de>
fabrics.c