I am sponsoring the following fasttrack for myself.  Micro/patch
binding is requested.  The proposal is a backwards compatible update
scsi_inquiry(9S) data structures and man pages to support more recient
versions SCSI standards.  I believe the case qualifies for self review,
and have filed it as Closed Approved Automatic.  If there is a request,
I'd be happy to convert it to a fasttrack and set the timer to enable
further discussion.

-Chris

1. Introduction
    1.1 Project/Component Working Name:
        scsi_inquiry(9S) update

    1.2 Name of Document Author/Supplier:
        Author: Chris Horne

    1.3 Date of This Document:
        Thu Oct 23 2008

4. Technical Description

    4.1 Summary

      This fasttrack proposes updates to the scsi_inquiry(9S) structure
      consistent with the evolution of SCSI standards.

    4.2 Interfaces

    4.2.1 Removed from man page:

        The following bits were specified in earlier versions of the
        ANSI standard, but generally unused - they have been removed
        from more recent versions of the ANSI standard.  The proposal
        is to remove these fields from the scsi_inquiry(9S) man page,
        the definition in the header file will still be there (marked
        deprecated).

        ------------------------------------------------------------------
        Interface Name  Comm.Lev.       Comments
        ------------------------------------------------------------------
        inq_reladdr     Obsolete        Supports relative addressing
        inq_wbus32        "             Supports 32 bit wide data xfers

    4.2.2 New (already defined in header file):

        These definitions update the scsi_inquiry(9S) man page to
        reflect definitions that already exist in the header file.

        ------------------------------------------------------------------
        Interface Name  Comm.Lev.       Comments
        ------------------------------------------------------------------
        DTYPE_RBC       Committed       Simplified direct-access device
        DTYPE_OCRW        "             Optical card reader/writer device.
        DTYPE_BRIDGE      "             Bridge
        DTYPE_OSD         "             Object-based storage device.

        DPQ_MASK          "             Mask Peripheral Qualifier field.


    4.2.3 NEW (Add to man page and header file):

        New fields in latest version of ANSI standard added to the man
        page and to the header file.

        ------------------------------------------------------------------
        Interface Name  Comm.Lev.       Comments
        ------------------------------------------------------------------
        inq_normaca     Committed       setting NACA bit supported
        inq_hisup         "             hierarchical addressing model
        inq_sccs          "             embedded storage array
        inq_tpgse         "             explicit asymmetric lun access
        inq_tpgsi         "             implicit asymmetric lun access
        inq_bque          "             basic queuing
        inq_encserv       "             embedded enclosure services
        inq_dualp         "             dual port device
        inq_mchngr        "             embedded/attached to medium chngr
        inq_addr16        "             SPI: supports 16 bit wide SCSI addr
        inq_clk           "             SPI3 clocking
        inq_qas           "             SPI3: quick arb sel
        inq_ius           "             SPI3: information units

    4.2.4 New (Add to the header file, no man page definition):

        New fields in latest version of ANSI standard added to the
        header file, but not being promoted to the man page at this
        time because of stability concerns.

        ------------------------------------------------------------------
        Interface Name  Comm.Lev.       Comments
        ------------------------------------------------------------------
        inq_acc         Unstable        access controls coordinator
        inq_3pc           "             third-party copy
        inq_protect       "             supports protection information

    4.2.5 Bugs fixed in current man page:

        The definition of the following fields are corrected: inq_ecma,
        inq_ansi.

        The man page is reorganized for consistent presentation of
        field definitions, using ANSI standard and structure layout
        order.

    4.2.6 Other changes

        In addition to the changes above, the following inquiry related
        implementation changes are being made:

        o The size of the scsi_inquiry(9S) structure is padded to 132
          bytes.  This is being done so that the sd_inq will contain
          vendor unique information needed for some of the mpxio
          failover modules.  The scsi_inquiry(9S) structure is not
          embedded in other structures, or used in kernel/user APIs -
          so this change should be safe.

        o The scsi_device(9S) 'sd_inq' information will now be scoped
          the same as the scsi_device(9S) structure itself (i.e.
          initchild - uninitchild), instead of by scsi_probe(9F) -
          scsi_unprobe(9F) (or scsi_slave(9F) - scsi_unslave(9F)).
          This change makes 'sd_inq' match the scope of a devinfo
          node's inquiry(9P) properties.  By coupling 'sd_inq' more
          closely with the devinfo state model, we reduce bugs related
          to a failed detach operations (making HBA driver and SCSA
          framework use of 'sd_inq' safer). This change makes the SCSA
          framework implementation of scsi_unprobe(9F) and
          scsi_unslave(9F) noops.

    4.3 Man page changes

        See below.

6.  Resources and Schedule

    6.4 Steering Committee requested information

    6.4.1 Consolidation C-team Name:
        ON

    6.5 ARC review type:
        FastTrack

A.1 Proposed scsi_inquiry(9F) man page changes:

--- scsi_inquiry.9s.orig        Thu Jul 21 21:02:18 2005
+++ scsi_inquiry.9s     Tue Aug  2 16:00:49 2005
@@ -1,3 +1,6 @@
+NOTE: Lines that start with 'X' will be deleted before submission,
+      they are being classified as unstable at this time.
+
 Data Structures for Drivers                      scsi_inquiry(9S)
 
 NAME
@@ -21,15 +24,27 @@
      uchar_t  inq_rmb          :1;   /* Removable media */
      uchar_t  inq_qual         :7;   /* Device type qualifier */
      uchar_t  inq_iso          :2;   /* ISO version */
-     uchar_t  inq_ecma         :3;   /* ANSI version */
+     uchar_t  inq_ecma         :3;   /* ECMA version */
+     uchar_t  inq_ansi         :3;   /* ANSII version */
      uchar_t  inq_aenc         :1;   /* Async event notification cap. */
      uchar_t  inq_trmiop       :1;   /* Supports TERMINATE I/O PROC msg */
+     uchar_t  inq_normaca      :1;   /* setting NACA bit supported */
+     uchar_t  inq_hisup        :1;   /* hierarchical addressing model */
      uchar_t  inq_rdf          :4;   /* Response data format */
-     uchar_t  inq_len;               /* Additional length */
-     uchar_t  inq_reladdr      :1;   /* Supports relative addressing */
-     uchar_t  inq_wbus32       :1;   /* Supports 32 bit wide data xfers */
-     uchar_t  inq_wbus16       :1;   /* Supports 16 bit wide data xfers */
-     uchar_t  inq_sync         :1;   /* Supports synchronous data xfers */
+     uchar_t  inq_len                /* Additional length */
+     uchar_t  inq_sccs         :1;   /* embedded storage array */
+X    uchar_t  inq_acc          :1;   /* access controls coordinator */
+     uchar_t  inq_tpgse        :1;   /* explicit asymmetric lun access */
+     uchar_t  inq_tpgsi        :1;   /* implicit asymmetric lun access */
+X    uchar_t  inq_3pc          :1;   /* third-party copy */
+X    uchar_t  inq_protect      :1;   /* supports protection information */
+     uchar_t  inq_bque         :1;   /* basic queueing */
+     uchar_t  inq_encserv      :1;   /* embedded enclosure services */
+     uchar_t  inq_dualp        :1;   /* dual port device */
+     uchar_t  inq_mchngr       :1;   /* embedded/attached to medium chngr */
+     uchar_t  inq_addr16       :1;   /* SPI: supports 16 bit wide SCSI addr */
+     uchar_t  inq_wbus16       :1;   /* SPI: Supports 16 bit wide data xfers */
+     uchar_t  inq_sync         :1;   /* SPI: Supports synchronous data xfers */
      uchar_t  inq_linked       :1;   /* Supports linked commands */
      uchar_t  inq_cmd_que      :1;   /* Supports command queueing */
      uchar_t  inq_sftre        :1;   /* Supports Soft Reset option */
@@ -36,6 +51,9 @@
      char     inq_vid[8];            /* Vendor ID */
      char     inq_pid[16];           /* Product ID */
      char     inq_revision[4];       /* Revision level */
+     uchar_t  inq_clk          :2;   /* SPI3 clocking */
+     uchar_t  inq_qas          :1;   /* SPI3: quick arb sel */
+     uchar_t  inq_ius          :1;   /* SPI3: information units */
 
 
      inq_dtype  identifies  the  type  of  device.  Bits  0  -  4
@@ -43,14 +61,9 @@
      represent the Peripheral Qualifier. The following values are
      appropriate for Peripheral Device Type field:
 
-     "small and bold">DTYPE_AArrayCcontroller device  (for  exam-
-                             ple, RAID).
-
      DTYPE_DIRECT            Direct-access device  (for  example,
                              magnetic disk).
 
-     DTYPE_ESI               Enclosure services device.
-
      DTYPE_SEQUENTIAL        Sequential-access device (for  exam-
                              ple, magnetic tape).
 
@@ -73,6 +86,19 @@
 
      DTYPE_COMM              Communications device.
 
+     DTYPE_ARRAY_CTRL        Array Controller device  (for  exam-
+                             ple, RAID).
+
+     DTYPE_ESI               Enclosure services device.
+
+     DTYPE_RBC               Simplified direct-access device
+
+     DTYPE_OCRW              Optical card reader/writer device.
+
+     DTYPE_BRDIGE            Bridge
+
+     DTYPE_OSD               Object-based storage device.
+
      DTYPE_UNKNOWN           Unknown or no device type.
 
      DTYPE_MASK              Mask to  isolate  Peripheral  Device
@@ -110,9 +136,9 @@
 
      DPQ_VUNIQ               This is a vendor-unique qualifier.
 
+     DPQ_MASK                Mask to  isolate  Peripheral  Qualifier
+                             field.
 
-
-
      DTYPE_NOTPRESENT is the peripheral qualifier  DPQ_NEVER  and
      the peripheral device type DTYPE_UNKNOWN combined.
 
@@ -133,22 +159,58 @@
      inq_trmiop, if set, indicates that the device  supports  the
      TERMINATE I/O PROCESS message.
 
-     inq_rdf, if reset, indicates the  INQUIRY data format is  as
-     specified in SCSI-1.
+     inq_normaca, if set, indicates that the device supports
+     setting the NACA bit to 1 in CDB.
 
-     inq_inq_len is the additional length  field  that  specifies
-     the length in bytes of the parameters.
+     inq_hisup, if set, indicates the SCSI target device uses
+     the hierarchical addressing model to assign LUNs to logical
+     units.
 
-     inq_reladdr, if set, indicates that the device supports  the
-     relative addressing mode of this logical unit.
+     inq_rdf, indicates the  INQUIRY data response data format:
+     RDF_LEVEL0 means that this structure complies with SCSI-1
+     spec, RDF_CCS means that this structure complies with CCS
+     pseudo-spec, and RDF_SCSI2 means that the structure
+     complies with the SCSI-2/3 spec.
 
-     inq_wbus32, if set, indicates that the device  supports  32-
-     bit wide data transfers.
+     inq_inq_len is the additional length  field  that
+     specifies the length in bytes of the parameters.
 
-     inq_wbus16, if set, indicates that the device  supports  16-
-     bit wide data transfers.
+     inq_sccs, if set, indicates the target device contains an
+     embedded storage array controller component.
 
-     inq_sync, if set, indicates that the  device  supports  syn-
+X    inq_acc, if set, indicates that the logical unit contains
+X    an access controls coordinator.
+
+     inq_tpgse, if set, indicates that implicit asymmetric
+     logical unit access is supported.
+
+     inq_tpgsi, if set, indicates that explicit asymmetric
+     logical unit access is supported.
+
+X    inq_3pc, if set, indicates that the SCSI target device
+X    supports third-party copy commands.
+
+X    inq_protect, if set, that the logical unit supports protection
+X    information.
+
+     inq_bque, if set, indicates that the logical unit supports
+     basic task management.
+
+     inq_encserv, if set, indicates that the device contains an
+     embedded enclosure services component (ses(7d)).
+
+     inq_dualp, if set, indicates the SCSI target device
+     supports two or more ports.
+
+     inq_mchngr, if set, indicates the SCSI target device
+     supports commands to control an attached media changer.
+
+     inq_addr16 device supports 16-bit wide SCSI addresses.
+
+     inq_wbus16, if set, indicates that the device  supports
+     16-bit wide data transfers.
+
+     inq_sync, if set, indicates that the  device  supports syn-
      chronous data transfers.
 
      inq_linked, if  set,  indicates  that  the  device  supports
@@ -162,19 +224,28 @@
      this bit is set, this indicates  that  the  device  responds
      with the soft  RESET alternative.
 
-     inq_vid contains eight bytes of  ASCII data identifying  the
+     inq_vid contains eight bytes of  ASCII data identifying the
      vendor of the product.
 
-     inq_pid contains sixteen bytes of  ASCII data as defined  by
-     the vendor.
-
-     inq_revision contains four bytes of  ASCII data  as  defined
+     inq_pid contains sixteen bytes of  ASCII data as defined
      by the vendor.
 
+     inq_revision contains four bytes of  ASCII data  as
+     defined by the vendor.
+
+     inq_clk clocking of SPI3 target port.
+
+     inq_qas SPI3 target port supports quick arbitration and
+     selection.
+
+     inq_ius SPI3 target device supports information unit transfers.
+
 SEE ALSO
      scsi_probe(9F), scsi_device(9S)
 
      ANSI Small Computer System Interface-2 (SCSI-2)
+     ANSII SCSI Primary Commands - 3 (SPC-3)
+     http://t10.org/drafts.htm#spc3
 
      Writing Device Drivers

Reply via email to