Print this page
701 UNMAP support for COMSTAR
Contributed by: Sumit Gupta <sumit.gupta@nexenta.com>
Reviewed by: Garrett D'Amore <garrett@nexenta.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/sys/scsi/generic/commands.h
          +++ new/usr/src/uts/common/sys/scsi/generic/commands.h
↓ open down ↓ 13 lines elided ↑ open up ↑
  14   14   * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15   15   * If applicable, add the following below this CDDL HEADER, with the
  16   16   * fields enclosed by brackets "[]" replaced with your own identifying
  17   17   * information: Portions Copyright [yyyy] [name of copyright owner]
  18   18   *
  19   19   * CDDL HEADER END
  20   20   */
  21   21  
  22   22  /*
  23   23   * Copyright (c) 1990, 2010, Oracle and/or its affiliates. All rights reserved.
       24 + *
       25 + * Copyright 2011 Nexenta Systems, Inc.  All rights reserved.
  24   26   */
  25   27  
  26   28  #ifndef _SYS_SCSI_GENERIC_COMMANDS_H
  27   29  #define _SYS_SCSI_GENERIC_COMMANDS_H
  28   30  
  29   31  #ifdef  __cplusplus
  30   32  extern "C" {
  31   33  #endif
  32   34  
  33   35  /*
↓ open down ↓ 192 lines elided ↑ open up ↑
 226  228  #define SCMD_SEARCH_HIGH        0x30
 227  229  #define SCMD_SEARCH_EQUAL       0x31
 228  230  #define SCMD_SEARCH_LOW         0x32
 229  231  #define SCMD_SET_LIMITS         0x33
 230  232  #define SCMD_SYNCHRONIZE_CACHE  0x35
 231  233  #define SCMD_READ_DEFECT_LIST   0x37
 232  234  #define SCMD_WRITE_BUFFER       0x3B
 233  235  #define SCMD_READ_BUFFER        0x3c
 234  236  #define SCMD_READ_LONG          0x3E
 235  237  #define SCMD_WRITE_LONG         0x3F
      238 +#define SCMD_WRITE_SAME_G1      0x41
      239 +#define SCMD_UNMAP              0x42
      240 +#define SCMD_GET_CONFIGURATION  0x46
      241 +#define SCMD_LOG_SELECT_G1      0x4c
      242 +#define SCMD_LOG_SENSE_G1       0x4d
 236  243  #define SCMD_RESERVE_G1         0x56
 237  244  #define SCMD_RELEASE_G1         0x57
 238  245  #define SCMD_MODE_SELECT_G1     0x55
 239  246  #define SCMD_MODE_SENSE_G1      0x5A
 240      -#define SCMD_GET_CONFIGURATION  0x46
 241      -#define SCMD_LOG_SELECT_G1      0x4C
 242      -#define SCMD_LOG_SENSE_G1       0x4d
 243  247  
 244  248  
 245  249  /*
 246  250   * Group 1 Commands, Sequential Access Devices
 247  251   */
 248  252  #define SCMD_LOCATE             0x2B    /* Note similarity to SCMD_SEEK_G1 */
 249  253  #define SCMD_READ_POSITION      0x34
 250  254  #define SCMD_REPORT_DENSITIES   0x44
 251  255  
 252  256  /*
↓ open down ↓ 73 lines elided ↑ open up ↑
 326  330  #define SCMD_GROUP4             0x80
 327  331  #define SCMD_EXTENDED_COPY      0x83
 328  332  #define SCMD_VERIFY_G4          0x8f
 329  333  
 330  334  /*
 331  335   * Group 4 Commands, Direct Access Devices
 332  336   */
 333  337  #define SCMD_READ_G4            0x88
 334  338  #define SCMD_WRITE_G4           0x8a
 335  339  #define SCMD_WRITE_VERIFY_G4    0x8e
      340 +#define SCMD_WRITE_SAME_G4      0x93
 336  341  #define SCMD_SVC_ACTION_IN_G4   0x9e
 337  342  #define SCMD_SVC_ACTION_OUT_G4  0x9f
 338  343  
 339  344  /*
 340  345   * Group 4 Service Actions for Service Action In (16)
 341  346   */
 342  347  #define SSVC_ACTION_READ_CAPACITY_G4    0x10
 343  348  #define SSVC_ACTION_READ_LONG_G4        0x11
 344  349  
 345  350  /*
↓ open down ↓ 102 lines elided ↑ open up ↑
 448  453  /* 0x33 */ SCMD_SET_LIMITS,             "set_limits",                   \
 449  454  /* 0x34 */ SCMD_READ_POSITION,          "read_position",                \
 450  455  /* 0x35 */ SCMD_SYNCHRONIZE_CACHE,      "synchronize_cache",            \
 451  456  /* 0x37 */ SCMD_READ_DEFECT_LIST,       "read_defect_data",             \
 452  457  /* 0x39 */ SCMD_COMPARE,                "compare",                      \
 453  458  /* 0x3a */ SCMD_COPY_VERIFY,            "copy_verify",                  \
 454  459  /* 0x3b */ SCMD_WRITE_BUFFER,           "write_buffer",                 \
 455  460  /* 0x3c */ SCMD_READ_BUFFER,            "read_buffer",                  \
 456  461  /* 0x3e */ SCMD_READ_LONG,              "read_long",                    \
 457  462  /* 0x3f */ SCMD_WRITE_LONG,             "write_long",                   \
      463 +/* 0x41 */ SCMD_WRITE_SAME_G1,          "write_same(10)",               \
      464 +/* 0x42 */ SCMD_UNMAP,                  "unmap",                        \
 458  465  /* 0x44 */ SCMD_REPORT_DENSITIES |                                      \
 459  466                  /* SCMD_READ_HEADER (from cdio.h) | */                  \
 460  467                  0,                      "report_densities/read_header", \
 461  468  /* 0x4c */ SCMD_LOG_SELECT_G1,          "log_select",                   \
 462  469  /* 0x4d */ SCMD_LOG_SENSE_G1,           "log_sense",                    \
 463  470  /* 0x55 */ SCMD_MODE_SELECT_G1,         "mode_select(10)",              \
 464  471  /* 0x56 */ SCMD_RESERVE_G1,             "reserve(10)",                  \
 465  472  /* 0x57 */ SCMD_RELEASE_G1,             "release(10)",                  \
 466  473  /* 0x5a */ SCMD_MODE_SENSE_G1,          "mode_sense(10)",               \
 467  474  /* 0x5e */ SCMD_PERSISTENT_RESERVE_IN,  "persistent_reserve_in",        \
↓ open down ↓ 2 lines elided ↑ open up ↑
 470  477  /* 0x81 */ SCMD_READ_REVERSE_G4,        "read_reverse(16)",             \
 471  478  /* 0x83 */ SCMD_EXTENDED_COPY,          "extended_copy",                \
 472  479  /* 0x88 */ SCMD_READ_G4,                "read(16)",                     \
 473  480  /* 0x8a */ SCMD_WRITE_G4,               "write(16)",                    \
 474  481  /* 0x8c */ SCMD_READ_ATTRIBUTE,         "read_attribute",               \
 475  482  /* 0x8d */ SCMD_WRITE_ATTRIBUTE,        "write_attribute",              \
 476  483  /* 0x8e */ SCMD_WRITE_VERIFY_G4,        "write_verify(16)",             \
 477  484  /* 0x8f */ SCMD_VERIFY_G4,              "verify(16)",                   \
 478  485  /* 0x91 */ SCMD_SPACE_G4,               "space(16)",                    \
 479  486  /* 0x92 */ SCMD_LOCATE_G4,              "locate(16)",                   \
      487 +/* 0x92 */ SCMD_WRITE_SAME_G4,          "write_same(16)",               \
 480  488  /* 0x9e */ SCMD_SVC_ACTION_IN_G4,       "service_action_in(16)",        \
 481  489  /* 0x9f */ SCMD_SVC_ACTION_OUT_G4,      "service_action_out(16)",       \
 482  490  /* 0xa0 */ SCMD_REPORT_LUNS,            "report_luns",                  \
 483  491  /* 0xa2 */ SCMD_SECURITY_PROTO_IN,      "security_protocol_in",         \
 484  492  /* 0xa3 */ SCMD_MAINTENANCE_IN,         "maintenance_in",               \
 485  493  /* 0xa4 */ SCMD_MAINTENANCE_OUT,        "maintenance_out",              \
 486  494  /* 0xa8 */ SCMD_READ_G5,                "read(12)",                     \
 487  495  /* 0xa9 */ SCMD_SVC_ACTION_OUT_G5,      "service_action_out(12)",       \
 488  496  /* 0xaa */ SCMD_WRITE_G5,               "write(12)",                    \
 489  497  /* 0xab */ SCMD_SVC_ACTION_IN_G5,       "service_action_in(12)",        \
↓ open down ↓ 26 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX