Re: [PATCH] kvm tools: Add initial virtio-scsi support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2012-08-14 at 07:45 +0100, Stefan Hajnoczi wrote:
> On Tue, Aug 14, 2012 at 09:52:55AM +0800, Asias He wrote:
> > On Mon, Aug 13, 2012 at 3:24 PM, Pekka Enberg <penberg@xxxxxxxxxx> wrote:
> > > On Thu, Aug 9, 2012 at 3:51 AM, Asias He <asias.hejun@xxxxxxxxx> wrote:

<SNIP>

> > >> ---
> > >> diff --git a/tools/kvm/include/kvm/disk-image.h b/tools/kvm/include/kvm/disk-image.h
> > >> index 7ae17f8..54e4047 100644
> > >> --- a/tools/kvm/include/kvm/disk-image.h
> > >> +++ b/tools/kvm/include/kvm/disk-image.h
> > >> @@ -41,6 +41,8 @@ struct disk_image_operations {
> > >>
> > >>  struct disk_image_params {
> > >>         const char *filename;
> > >> +       const char *wwpn;
> > >> +       const char *tpgt;
> > >
> > > Maybe it's just me but "wwpn" and "tpgt" really could use a comment
> > > explaining what they are...
> > 
> > OK. They are terminology from linux target.
> > 
> >    wwpn == world wide port number
> >    tpgt == target port group tag
> 
> Target Portal Group Tag
> 
> TPGT is iSCSI-specific terminology but other transports like SAS or FCP
> have similar concepts of naming target ports.  I think this terminology
> is used by the LIO target regardless of the fabric.
> 
> The SCSI Architecture Model standard says the target port name is the
> "name (see 3.1.70) of a SCSI target port that is world wide unique
> within the SCSI transport protocol of the SCSI domain of that SCSI
> target port".
> 

The idea of a TargetPortalGroupTag originally came from iSCSI to do
logical partitioning of a single TargetName (IQN or EUI) instance with
different LUN/auth/network portal configurations.  For iSCSI fabrics,
the SCSI target WWPN takes the form of a symbolic string as:

    $TARGETNAME+t+0x$TPGT

In generic target_core_fabric_configfs.c code, all SCSI target endpoints
are attached to se_portal_group->tpg_group residing individually
at /sys/kernel/config/target/$FABRIC/$FABRIC_WWN/$TPGT/.  It's parent
configfs group is at se_wwn->wwn_group, who's higher level parent is the
top level fabric group registered by the fabric driver with TCM.

So the $FABRIC_WWN/$TPGT/[luns,acls] groups hang off this primary
config_group, which means that currently non iSCSI target based fabric
drivers are required to individually enforce TPGT=1 usage in their own
code when mapping SCSI target WWPNs to underlying storage HW WWPNs, or a
fabric using software based WWPNs (as iSCSI does).

Also, from the user level of rtsadmin/targetcli we do hide the notion of
TPGTs for all non iscsi fabrics, however using rtslib directly does
still require following the underlying $FABRIC/$FABRIC_WWN/$TPGT/ object
layout.

--nab

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux