On Sun, Jun 07, 2020 at 03:35:49PM -0500, Mike Christie wrote: > The PGR code assumes the ACL name is going to be based on the SPC4 > transportID type of values. The problem is that for iSCSI we have an extra > session id as part of the SCSI port id and some fabric modules support or > would like to support non transportID values for the ACL name. For example, > iSCSI and SRP would like to use the source address for the ACL name, but > that is not a valud transportID value that you can get in a PGR request. > > This patch adds a new transport_id struct which maps to the SPC4 > transportID. In the future it will be used for PGR commands instead of the > ACL name. In this patchset it is used to export the initiator info in the > session's sysfs dir, so tools can display the info and daemons that execute > commands like PGRs in userspace can build a session id to I_T nexus mapping. > > In this patch only srp is passing in different values for the transport id > and acl name. The next patches will convert loop, scsi vhost and xen > scsiback that are more complex due to their initiator name emulation. > > Cc: Michael S. Tsirkin <mst@xxxxxxxxxx> > Cc: Jason Wang <jasowang@xxxxxxxxxx> > Cc: Paolo Bonzini <pbonzini@xxxxxxxxxx> > Cc: Stefan Hajnoczi <stefanha@xxxxxxxxxx> > Cc: Juergen Gross <jgross@xxxxxxxx> > Signed-off-by: Mike Christie <michael.christie@xxxxxxxxxx> > Reviewed-by: Hannes Reinecke <hare@xxxxxxx> > Reviewed-by: Lee Duncan <lduncan@xxxxxxxx> > --- > drivers/infiniband/ulp/srpt/ib_srpt.c | 10 +++++--- > drivers/scsi/ibmvscsi_tgt/ibmvscsi_tgt.c | 4 +-- > drivers/scsi/qla2xxx/tcm_qla2xxx.c | 2 +- > drivers/target/loopback/tcm_loop.c | 3 ++- > drivers/target/sbp/sbp_target.c | 2 +- > drivers/target/target_core_fabric_lib.c | 41 +++++++++++++++++++++++++++++++ > drivers/target/target_core_transport.c | 42 ++++++++++++++++++++++++-------- > drivers/target/tcm_fc/tfc_sess.c | 3 ++- > drivers/usb/gadget/function/f_tcm.c | 3 ++- > drivers/vhost/scsi.c | 1 + > drivers/xen/xen-scsiback.c | 3 ++- > include/target/target_core_base.h | 12 +++++++++ > include/target/target_core_fabric.h | 5 +++- > 13 files changed, 108 insertions(+), 23 deletions(-) For drivers/vhost/scsi.c: Reviewed-by: Stefan Hajnoczi <stefanha@xxxxxxxxxx>
Attachment:
signature.asc
Description: PGP signature