]> git.baikalelectronics.ru Git - kernel.git/commit
scsi: scsi_transport_fc: Add dummy initiator role to rport
authorCathy Avery <cavery@redhat.com>
Mon, 17 Apr 2017 18:37:45 +0000 (14:37 -0400)
committerMartin K. Petersen <martin.petersen@oracle.com>
Wed, 19 Apr 2017 23:13:52 +0000 (19:13 -0400)
commit4356e66340dcaa031477c02e7b31a0c1c12aa447
treee083c5c5dc8691617f312e36051bac5b284a714c
parentf15fcc1bc88cd91b04e7b41aef25219852fb9c10
scsi: scsi_transport_fc: Add dummy initiator role to rport

This patch allows scsi drivers that expose virturalized fibre channel
devices but that do not expose rports to successfully rescan the scsi
bus via echo "- - -" > /sys/class/scsi_host/hostX/scan.  Drivers can
create a pseudo rport and indicate FC_PORT_ROLE_FCP_DUMMY_INITIATOR as
the rport's role in fc_rport_identifiers. This insures that a valid
scsi_target_id is assigned to the newly created rport and it can meet
the requirements of fc_user_scan_tgt calling scsi_scan_target.

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/scsi_transport_fc.c
include/scsi/scsi_transport_fc.h