Print this page
NEX-3705 Need to update libses with LID/USN code from sesctld
Reviewed by: Dan Fields <dan.fields@nexenta.com>
Reviewed by: Rob Gittins <rob.gittins@nexenta.com>
Reviewed by: Hans Rosenfeld <hans.rosenfeld@nexenta.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/lib/scsi/libscsi/common/libscsi_impl.h
          +++ new/usr/src/lib/scsi/libscsi/common/libscsi_impl.h
↓ open down ↓ 14 lines elided ↑ open up ↑
  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 2008 Sun Microsystems, Inc.  All rights reserved.
  24   24   * Use is subject to license terms.
       25 + * Copyright 2015 Nexenta Systems, Inc.  All rights reserved.
  25   26   */
  26   27  
  27   28  #ifndef _LIBSCSI_IMPL_H
  28   29  #define _LIBSCSI_IMPL_H
  29   30  
  30   31  #pragma ident   "%Z%%M% %I%     %E% SMI"
  31   32  
  32   33  #ifdef  __cplusplus
  33   34  extern "C" {
  34   35  #endif
↓ open down ↓ 31 lines elided ↑ open up ↑
  66   67          char lsh_errmsg[LIBSCSI_ERRMSGLEN];
  67   68          libscsi_engine_impl_t *lsh_engines;
  68   69          uint_t lsh_targets;
  69   70  };
  70   71  
  71   72  struct libscsi_target {
  72   73          const libscsi_engine_t *lst_engine;
  73   74          char *lst_vendor;
  74   75          char *lst_product;
  75   76          char *lst_revision;
       77 +        char *lst_lid;
       78 +        char *lst_usn;
  76   79          void *lst_priv;
  77   80          uint_t lst_mtbf_cdb;
  78   81          uint_t lst_mtbf_read;
  79   82          uint_t lst_mtbf_write;
  80   83          struct libscsi_hdl *lst_hdl;
  81   84  };
  82   85  
  83   86  #define VERIFY(x)       ((void)((x) || libscsi_assert(#x, __FILE__, __LINE__)))
  84   87  
  85   88  #ifdef DEBUG
  86   89  #define ASSERT(x)       VERIFY(x)
  87   90  #else
  88   91  #define ASSERT(x)
  89   92  #endif
  90   93  
  91   94  #define LXOR(l, r)      (((l) != 0) ^ ((r) != 0))
  92   95  
  93   96  extern int libscsi_assert(const char *, const char *, int);
  94   97  extern int libscsi_get_inquiry(struct libscsi_hdl *, struct libscsi_target *);
       98 +extern int libscsi_get_inquiry_dev_id(struct libscsi_hdl *,
       99 +    struct libscsi_target *);
      100 +extern int libscsi_get_inquiry_usn(struct libscsi_hdl *,
      101 +    struct libscsi_target *);
  95  102  
  96  103  #ifdef  __cplusplus
  97  104  }
  98  105  #endif
  99  106  
 100  107  #endif  /* _LIBSCSI_IMPL_H */
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX