Template Version: @(#)sac_nextcase 1.68 02/23/09 SMI
This information is Copyright 2009 Sun Microsystems
1. Introduction
    1.1. Project/Component Working Name:
         DTrace COMSTAR SCSI RDMA Protocol Target Provider
    1.2. Name of Document Author/Supplier:
         Author:  Charles Ting
    1.3  Date of This Document:
        03 June, 2009
4. Technical Description
Template Version: @(#)sac_nextcase 1.64 07/13/07 SMI
This information is Copyright 2009 Sun Microsystems
1. Introduction
   1.1. Project/Component Working Name:
        DTrace COMSTAR SCSI RDMA Protocol Target Provider
   1.2. Name of Document Author/Supplier:
        Author:  Charles Ting
   1.3  Date of This Document:
        01 June, 2009
4. Technical Description

The following specification describes the COMSTAR SRP Target
provider for DTrace. It has been reviewed and approved by the DTrace
community; the PSARC case is closed approved automatic to record the
interface. The stability is Committed and the binding is Patch.

The srp provider provides probes for tracing SRP port provider activity.

This is a kernel provider built into the COMSTAR srp target port provider.

SRP Provider

4.1 Probes overview

SRP Event Type                  Probes
------------------------        ------
Service up/down events          srp:::service-up
                                srp:::service-down

Login/logout                    srp:::login-command
                               srp:::login-response
                               srp:::logout-command

Task cwcommand/response         srp:::task-command
                               srp:::task-response

SCSI command/response           srp:::scsi-command
                               srp:::scsi-response

Buffer dispatch/completion      srp:::xfer-start
                               srp:::xfer-done

4.2 Probe argument commonality

4.2.1 Arguments common to all probes.

All SRP probes have the first and second arguments in common:

       args[0]         conninfo_t *            srp connection information

The conninfo_t structure is already used by the iSCSI target provider (iscsi),
and is intended for use by all provider which are providing some higher
level protocol (e.g. iscsi, nfs, http, ftp).

       typedef struct conninfo {
               string ci_local;        /* GID of the local HCA */
               string ci_remote;       /* GID of the remote HCA */
               string ci_protocol;     /* protocol (ib) */
       } conninfo_t;


        args[1]         srp_portinfo_t *        srp port information

The srp_portinfo_t structure contains detailed information about a SRP 
connection:

        typedef struct srp_portinfo {
                string  pi_initiator;   /* Initiator EUI name */
                string  pi_i_sid;       /* Initiator session id */
                string  pi_target;      /* Target EUI name */
                string  pi_t_sid;       /* Target session id */
                uintptr_t pi_chan_id;   /* Channel identifier */
        } srp_portinfo_t;
        
4.2.2 Arguments common to SRP login-command and login-response probes.

        args[2]         srp_logininfo_t *       srp login information

The srp_logininfo_t structure contains the information about login parameters
or the reason code of login failure.

        typedef struct srp_logininfo {
                /* SRP task tag */
                uint64_t li_task_tag;
                /* Maximum iu length that initiator can send to target */
                uint32_t li_max_it_iu_len;
                /* Maximum iu length that target can send to initiator */
                uint32_t li_max_ti_iu_len;
                /* Maximum number of SRP requests that initiator can send
                   on a channel */
                uint32_t li_request_limit;
        } srp_logininfo_t;

4.2.3 Arguments common to scsi-command, scsi-response, task-command and
task-response probes.

        Argument for scsi-response, task-command and task-response probes:

        args[2]         srp_taskinfo *          srp task information

The srp_taskinfo_t structure contains information about a srp task.

        typedef struct srp_taskinfo {
                /* SRP task tag */
        uint64_t ti_task_tag;
                /* Target logical unit number */
                uint64_t ti_lun;
                /* Task management function */
                uint8_t  ti_function;
                /* Increment of channel's request limit */
                uint32_t ti_req_limit_delta;
                /* bit 2:DOOVER 3:DOUNDER 4:DIOVER 5:DIUNDER */
                uint8_t  ti_flag;
                /* Data-out residual count */
                uint32_t ti_do_resid_cnt;
                /* Data-in residual count */
                uint32_t ti_di_resid_cnt;
                /* Status of this task */
                uint8_t  ti_status;
        } srp_taskinfo_t;       

        
        Arguments for scsi-command probe:               

       args[2]         scsicmd_t *              SCSI command block (cdb)
       args[3]         srp_taskinfo *           srp task information

The scsicmd_t structure contains information about SCSI command blocks:

       typedef struct scsicmd {
               uint64_t ic_len;        /* CDB length */
               uint8_t  *ic_cdb;       /* CDB data */
       } scsicmd_t;

4.2.4 Arguments common to xfer-start and xfer-done probes.

       args[2]         xferinfo_t *         data transfer information

The xferinfo_t structure contains information about the data transfer.

        typedef struct xferinfo {
                /* local buffer address */
                uintptr_t xfer_laddr;
                /* offset within the local buffer */
                uint32_t xfer_loffset;
                /* access control to local memory */
                uint32_t xfer_lkey;
                /* remote virtual address */
                uintptr_t xfer_raddr;
                /* offset from the remote address */
                uint32_t xfer_roffset;
                /* access control to remote virtual address */
                uint32_t xfer_rkey;
                /* transfer length */
                uint32_t xfer_len;
                /* Read or Write */
                uint32_t xfer_type;
        } xferinfo_t;


4.3 Probes summary

Events                  Probes                  Arguments
-----------------------------------------------------------------------------
Service up              service-up              arg[0]     conninfo_t *
                                                arg[1]     srp_portinfo_t *
-----------------------------------------------------------------------------
Service down            service-down            arg[0]     conninfo_t *
                                                arg[1]     srp_portinfo_t *
-----------------------------------------------------------------------------
Login command           login-command           arg[0]     conninfo_t *
                                                arg[1]     srp_portinfo_t *
                                                arg[2]     srp_logininfo_t *
-----------------------------------------------------------------------------
Login response          login-response          arg[0]     conninfo_t *
                                                arg[1]     srp_portinfo_t *
                                                arg[2]     srp_logininfo_t *
-----------------------------------------------------------------------------
Logout command          logout-command          arg[0]     conninfo_t *
                                                arg[1]     srp_portinfo_t *
-----------------------------------------------------------------------------
SCSI command            scsi-command            arg[0]     conninfo_t *
                                                arg[1]     srp_portinfo_t *
                                                arg[2]     scsicmd_t *
                                                arg[3]     srp_taskinfo_t *
-----------------------------------------------------------------------------
SCSI response           scsi-response           arg[0]     conninfo_t *
                                                arg[1]     srp_portinfo_t *
                                                arg[2]     srp_taskinfo_t *
-----------------------------------------------------------------------------
Task command            task-command            arg[0]     conninfo_t *
                                                arg[1]     srp_portinfo_t *
                                                arg[2]     srp_taskinfo_t *
-----------------------------------------------------------------------------
Task response           task-response           arg[0]     conninfo_t *
                                                arg[1]     srp_portinfo_t *
                                                arg[2]     srp_taskinfo_t *
-----------------------------------------------------------------------------
Buffer dispatch         xfer-start              arg[0]     conninfo_t *
                                                arg[1]     srp_portinfo_t *
                                                arg[2]     xferinfo_t *
-----------------------------------------------------------------------------
Buffer completion       xfer-done               arg[0]     conninfo_t *
                                                arg[1]     srp_portinfo_t *
                                                arg[2]     xferinfo_t;
-----------------------------------------------------------------------------

Documentation and examples can be found here:

 http://wikis.sun.com/display/DTrace/srp+port+Provider

The table below describes the DTrace stability levels

                |  Name            Data            Class                       
   -------------+-------------------------------------------
   Provider     |  Evolving        Evolving        ISA     
   Module       |  Private         Private         Unknown
   Function     |  Private         Private         Unknown
   Name         |  Evolving        Evolving        ISA   
   Arguments    |  Evolving        Evolving        ISA


6. Resources and Schedule
   6.4. Steering Committee requested information
       6.4.1. Consolidation C-team Name:
               OS/Net
   6.5. ARC review type: FastTrack
   6.6. ARC Exposure: open

6. Resources and Schedule
    6.4. Steering Committee requested information
        6.4.1. Consolidation C-team Name:
                OS/Net
    6.5. ARC review type: Automatic
    6.6. ARC Exposure: open


Reply via email to