scsi: storvsc: Add support for FC rport.
authorCathy Avery <cavery@redhat.com>
Mon, 17 Apr 2017 18:37:46 +0000 (14:37 -0400)
committerMartin K. Petersen <martin.petersen@oracle.com>
Wed, 19 Apr 2017 23:14:14 +0000 (19:14 -0400)
commitdaf0cd445a218314f9461d67d4f2b9c24cdd534b
tree5ccdd2d32ded15a00834487ddf696acc419c175a
parent0c3ae2664766ec892992a686e48ead94784ef54c
scsi: storvsc: Add support for FC rport.

Included in the current storvsc driver for Hyper-V is the ability to
access luns on an FC fabric via a virtualized fiber channel adapter
exposed by the Hyper-V host. The driver also attaches to the FC
transport to allow host and port names to be published under
/sys/class/fc_host/hostX. Current customer tools running on the VM
require that these names be available in the well known standard
location under fc_host/hostX.

This patch stubs in an rport per fc_host and sets its rport role as
FC_PORT_ROLE_FCP_DUMMY_INITIATOR to indicate to the fc_transport that it
is a pseudo rport in order to scan the scsi stack via echo "- - -" >
/sys/class/scsi_host/hostX/scan.

Signed-off-by: Cathy Avery <cavery@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/storvsc_drv.c