Print this page
LOCAL: mpt_sas: expose drive ID via ioctl

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/io/scsi/adapters/mpt_sas/mptsas.c
          +++ new/usr/src/uts/common/io/scsi/adapters/mpt_sas/mptsas.c
↓ 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 (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
  24   24   * Copyright 2012 Nexenta Systems, Inc. All rights reserved.
       25 + * Copyright (c) 2012, Joyent, Inc. All rights reserved.
  25   26   */
  26   27  
  27   28  /*
  28   29   * Copyright (c) 2000 to 2010, LSI Corporation.
  29   30   * All rights reserved.
  30   31   *
  31   32   * Redistribution and use in source and binary forms of all code within
  32   33   * this file that is exclusively owned by LSI, with or without
  33   34   * modification, is permitted provided that, in addition to the CDDL 1.0
  34   35   * License requirements, the following conditions are met:
↓ open down ↓ 27 lines elided ↑ open up ↑
  62   63  
  63   64  /*
  64   65   * standard header files.
  65   66   */
  66   67  #include <sys/note.h>
  67   68  #include <sys/scsi/scsi.h>
  68   69  #include <sys/pci.h>
  69   70  #include <sys/file.h>
  70   71  #include <sys/cpuvar.h>
  71   72  #include <sys/policy.h>
       73 +#include <sys/model.h>
  72   74  #include <sys/sysevent.h>
  73   75  #include <sys/sysevent/eventdefs.h>
  74   76  #include <sys/sysevent/dr.h>
  75   77  #include <sys/sata/sata_defs.h>
  76   78  #include <sys/scsi/generic/sas.h>
  77   79  #include <sys/scsi/impl/scsi_sas.h>
  78   80  
  79   81  #pragma pack(1)
  80   82  #include <sys/scsi/adapters/mpt_sas/mpi/mpi2_type.h>
  81   83  #include <sys/scsi/adapters/mpt_sas/mpi/mpi2.h>
↓ open down ↓ 280 lines elided ↑ open up ↑
 362  364      uint16_t *handle, mptsas_target_t **pptgt);
 363  365  static void mptsas_update_phymask(mptsas_t *mpt);
 364  366  static inline void mptsas_remove_cmd0(mptsas_t *mpt, mptsas_cmd_t *cmd);
 365  367  
 366  368  static int mptsas_send_sep(mptsas_t *mpt, mptsas_target_t *ptgt,
 367  369      uint32_t *status, uint8_t cmd);
 368  370  static dev_info_t *mptsas_get_dip_from_dev(dev_t dev,
 369  371      mptsas_phymask_t *phymask);
 370  372  static mptsas_target_t *mptsas_addr_to_ptgt(mptsas_t *mpt, char *addr,
 371  373      mptsas_phymask_t phymask);
 372      -static int mptsas_set_led_status(mptsas_t *mpt, mptsas_target_t *ptgt,
 373      -    uint32_t slotstatus);
      374 +static int mptsas_flush_led_status(mptsas_t *mpt, mptsas_target_t *ptgt);
 374  375  
 375  376  
 376  377  /*
 377  378   * Enumeration / DR functions
 378  379   */
 379  380  static void mptsas_config_all(dev_info_t *pdip);
 380  381  static int mptsas_config_one_addr(dev_info_t *pdip, uint64_t sasaddr, int lun,
 381  382      dev_info_t **lundip);
 382  383  static int mptsas_config_one_phy(dev_info_t *pdip, uint8_t phy, int lun,
 383  384      dev_info_t **lundip);
↓ open down ↓ 698 lines elided ↑ open up ↑
1082 1083          }
1083 1084  
1084 1085          mpt = ddi_get_soft_state(mptsas_state, instance);
1085 1086  
1086 1087          if (mpt == NULL) {
1087 1088                  mptsas_log(NULL, CE_WARN,
1088 1089                      "mptsas%d: cannot get soft state", instance);
1089 1090                  goto fail;
1090 1091          }
1091 1092  
     1093 +        /* Mark us as a primary ioctl node for an instance. */
     1094 +        (void) ddi_prop_update_int(DDI_DEV_T_NONE, dip, "primary-ioctl-node",
     1095 +            instance);
     1096 +
1092 1097          /* Indicate that we are 'sizeof (scsi_*(9S))' clean. */
1093 1098          scsi_size_clean(dip);
1094 1099  
1095 1100          mpt->m_dip = dip;
1096 1101          mpt->m_instance = instance;
1097 1102  
1098 1103          /* Make a per-instance copy of the structures */
1099 1104          mpt->m_io_dma_attr = mptsas_dma_attrs64;
1100 1105          mpt->m_msg_dma_attr = mptsas_dma_attrs;
1101 1106          mpt->m_reg_acc_attr = mptsas_dev_attr;
↓ open down ↓ 5342 lines elided ↑ open up ↑
6444 6449                              DDI_PROP_SUCCESS) {
6445 6450                                  (void) ddi_prop_remove(DDI_DEV_T_NONE, parent,
6446 6451                                      MPTSAS_VIRTUAL_PORT);
6447 6452                                  mptsas_log(mpt, CE_WARN, "mptsas virtual port "
6448 6453                                      "prop update failed");
6449 6454                                  break;
6450 6455                          }
6451 6456                  }
6452 6457  
6453 6458                  mutex_enter(&mpt->m_mutex);
6454      -                if (mptsas_set_led_status(mpt, ptgt, 0) != DDI_SUCCESS) {
     6459 +                ptgt->m_led_status = 0;
     6460 +                if (mptsas_flush_led_status(mpt, ptgt) != DDI_SUCCESS) {
6455 6461                          NDBG14(("mptsas: clear LED for tgt %x failed",
6456 6462                              ptgt->m_slot_num));
6457 6463                  }
6458 6464                  if (rval == DDI_SUCCESS) {
6459 6465                          mptsas_tgt_free(&mpt->m_active->m_tgttbl,
6460 6466                              ptgt->m_sas_wwn, ptgt->m_phymask);
6461 6467                          ptgt = NULL;
6462 6468                  } else {
6463 6469                          /*
6464 6470                           * clean DR_INTRANSITION flag to allow I/O down to
↓ open down ↓ 5479 lines elided ↑ open up ↑
11944 11950                  }
11945 11951          } else {
11946 11952                  status = EFAULT;
11947 11953          }
11948 11954  
11949 11955          mutex_exit(&mpt->m_mutex);
11950 11956          return (status);
11951 11957  }
11952 11958  
11953 11959  static int
     11960 +led_control(mptsas_t *mpt, intptr_t data, int mode)
     11961 +{
     11962 +        int ret = 0;
     11963 +        mptsas_led_control_t lc;
     11964 +        mptsas_target_t *ptgt;
     11965 +
     11966 +        if (ddi_copyin((void *)data, &lc, sizeof (lc), mode) != 0) {
     11967 +                return (EFAULT);
     11968 +        }
     11969 +
     11970 +        if ((lc.Command != MPTSAS_LEDCTL_FLAG_SET &&
     11971 +            lc.Command != MPTSAS_LEDCTL_FLAG_GET) ||
     11972 +            lc.Led < MPTSAS_LEDCTL_LED_IDENT ||
     11973 +            lc.Led > MPTSAS_LEDCTL_LED_OK2RM) {
     11974 +                return (EINVAL);
     11975 +        }
     11976 +
     11977 +        /* Locate the target we're interrogating... */
     11978 +        mutex_enter(&mpt->m_mutex);
     11979 +        ptgt = (mptsas_target_t *)mptsas_hash_traverse(&mpt->m_active->m_tgttbl,
     11980 +            MPTSAS_HASH_FIRST);
     11981 +        while (ptgt != NULL) {
     11982 +                if (ptgt->m_enclosure == lc.Enclosure &&
     11983 +                    ptgt->m_slot_num == lc.Slot) {
     11984 +                        break;
     11985 +                }
     11986 +                ptgt = (mptsas_target_t *)mptsas_hash_traverse(
     11987 +                    &mpt->m_active->m_tgttbl, MPTSAS_HASH_NEXT);
     11988 +        }
     11989 +        if (ptgt == NULL) {
     11990 +                /* We could not find a target for that enclosure/slot. */
     11991 +                mutex_exit(&mpt->m_mutex);
     11992 +                return (ENOENT);
     11993 +        }
     11994 +
     11995 +        if (lc.Command == MPTSAS_LEDCTL_FLAG_SET) {
     11996 +                /* Update our internal LED state. */
     11997 +                ptgt->m_led_status &= ~(1 << (lc.Led - 1));
     11998 +                ptgt->m_led_status |= (!!lc.LedStatus) << (lc.Led - 1);
     11999 +
     12000 +                /* Flush it to the controller. */
     12001 +                ret = mptsas_flush_led_status(mpt, ptgt);
     12002 +                mutex_exit(&mpt->m_mutex);
     12003 +                return (ret);
     12004 +        }
     12005 +
     12006 +        /* Return our internal LED state. */
     12007 +        lc.LedStatus = !!(ptgt->m_led_status & (1 << (lc.Led - 1)));
     12008 +        mutex_exit(&mpt->m_mutex);
     12009 +
     12010 +        if (ddi_copyout(&lc, (void *)data, sizeof (lc), mode) != 0) {
     12011 +                return (EFAULT);
     12012 +        }
     12013 +
     12014 +        return (0);
     12015 +}
     12016 +
     12017 +static int
     12018 +get_disk_info(mptsas_t *mpt, intptr_t data, int mode)
     12019 +{
     12020 +        int i;
     12021 +        int count = 0;
     12022 +        int ret = 0;
     12023 +        mptsas_target_t *ptgt;
     12024 +        mptsas_disk_info_t *di;
     12025 +        STRUCT_DECL(mptsas_get_disk_info, gdi);
     12026 +
     12027 +        STRUCT_INIT(gdi, get_udatamodel());
     12028 +
     12029 +        if (ddi_copyin((void *)data, STRUCT_BUF(gdi), STRUCT_SIZE(gdi),
     12030 +            mode) != 0) {
     12031 +                return (EFAULT);
     12032 +        }
     12033 +
     12034 +restart:
     12035 +        /* Find out how many targets there are. */
     12036 +        mutex_enter(&mpt->m_mutex);
     12037 +        ptgt = (mptsas_target_t *)mptsas_hash_traverse(&mpt->m_active->m_tgttbl,
     12038 +            MPTSAS_HASH_FIRST);
     12039 +        while (ptgt != NULL) {
     12040 +                count++;
     12041 +                ptgt = (mptsas_target_t *)mptsas_hash_traverse(
     12042 +                    &mpt->m_active->m_tgttbl, MPTSAS_HASH_NEXT);
     12043 +        }
     12044 +        mutex_exit(&mpt->m_mutex);
     12045 +
     12046 +        /*
     12047 +         * If we haven't been asked to copy out information on each target,
     12048 +         * then just return the count.
     12049 +         */
     12050 +        STRUCT_FSET(gdi, DiskCount, count);
     12051 +        if (STRUCT_FGETP(gdi, PtrDiskInfoArray) == NULL)
     12052 +                goto copy_out;
     12053 +
     12054 +        /*
     12055 +         * If we haven't been given a large enough buffer to copy out into,
     12056 +         * let the caller know.
     12057 +         */
     12058 +        if (STRUCT_FGET(gdi, DiskInfoArraySize) <
     12059 +            count * sizeof (mptsas_disk_info_t)) {
     12060 +                ret = ENOSPC;
     12061 +                goto copy_out;
     12062 +        }
     12063 +
     12064 +        di = kmem_zalloc(count * sizeof (mptsas_disk_info_t), KM_SLEEP);
     12065 +
     12066 +        mutex_enter(&mpt->m_mutex);
     12067 +        i = 0;
     12068 +        ptgt = (mptsas_target_t *)mptsas_hash_traverse(&mpt->m_active->m_tgttbl,
     12069 +            MPTSAS_HASH_FIRST);
     12070 +        while (ptgt != NULL) {
     12071 +                if (i >= count) {
     12072 +                        /*
     12073 +                         * The number of targets changed while we weren't
     12074 +                         * looking.  Go again.
     12075 +                         */
     12076 +                        mutex_exit(&mpt->m_mutex);
     12077 +                        kmem_free(di, count * sizeof (mptsas_disk_info_t));
     12078 +                        goto restart;
     12079 +                }
     12080 +                di[i].Instance = mpt->m_instance;
     12081 +                di[i].Enclosure = ptgt->m_enclosure;
     12082 +                di[i].Slot = ptgt->m_slot_num;
     12083 +                di[i].SasAddress = ptgt->m_sas_wwn;
     12084 +
     12085 +                ptgt = (mptsas_target_t *)mptsas_hash_traverse(
     12086 +                    &mpt->m_active->m_tgttbl, MPTSAS_HASH_NEXT);
     12087 +                i++;
     12088 +        }
     12089 +        mutex_exit(&mpt->m_mutex);
     12090 +        STRUCT_FSET(gdi, DiskCount, i);
     12091 +
     12092 +        /* Copy out the disk information to the caller. */
     12093 +        if (ddi_copyout((void *)di, STRUCT_FGETP(gdi, PtrDiskInfoArray),
     12094 +            i * sizeof (mptsas_disk_info_t), mode) != 0) {
     12095 +                ret = EFAULT;
     12096 +        }
     12097 +
     12098 +        kmem_free(di, count * sizeof (mptsas_disk_info_t));
     12099 +
     12100 +copy_out:
     12101 +        if (ddi_copyout(STRUCT_BUF(gdi), (void *)data, STRUCT_SIZE(gdi),
     12102 +            mode) != 0) {
     12103 +                ret = EFAULT;
     12104 +        }
     12105 +
     12106 +        return (ret);
     12107 +}
     12108 +
     12109 +static int
11954 12110  mptsas_ioctl(dev_t dev, int cmd, intptr_t data, int mode, cred_t *credp,
11955 12111      int *rval)
11956 12112  {
11957 12113          int                     status = 0;
11958 12114          mptsas_t                *mpt;
11959 12115          mptsas_update_flash_t   flashdata;
11960 12116          mptsas_pass_thru_t      passthru_data;
11961 12117          mptsas_adapter_data_t   adapter_data;
11962 12118          mptsas_pci_info_t       pci_info;
11963 12119          int                     copylen;
↓ open down ↓ 66 lines elided ↑ open up ↑
12030 12186                                      "found", addr));
12031 12187                                  ndi_dc_freehdl(dcp);
12032 12188                                  goto out;
12033 12189                          }
12034 12190                          mutex_enter(&mpt->m_mutex);
12035 12191                          if (cmd == DEVCTL_DEVICE_ONLINE) {
12036 12192                                  ptgt->m_tgt_unconfigured = 0;
12037 12193                          } else if (cmd == DEVCTL_DEVICE_OFFLINE) {
12038 12194                                  ptgt->m_tgt_unconfigured = 1;
12039 12195                          }
12040      -                        slotstatus = 0;
12041      -#ifdef MPTSAS_GET_LED
12042      -                        /*
12043      -                         * The get led status can't get a valid/reasonable
12044      -                         * state, so ignore the get led status, and write the
12045      -                         * required value directly
12046      -                         */
12047      -                        if (mptsas_get_led_status(mpt, ptgt, &slotstatus) !=
12048      -                            DDI_SUCCESS) {
12049      -                                NDBG14(("mptsas_ioctl: get LED for tgt %s "
12050      -                                    "failed %x", addr, slotstatus));
12051      -                                slotstatus = 0;
12052      -                        }
12053      -                        NDBG14(("mptsas_ioctl: LED status %x for %s",
12054      -                            slotstatus, addr));
12055      -#endif
12056 12196                          if (cmd == DEVCTL_DEVICE_OFFLINE) {
12057      -                                slotstatus |=
12058      -                                    MPI2_SEP_REQ_SLOTSTATUS_REQUEST_REMOVE;
     12197 +                                ptgt->m_led_status |=
     12198 +                                    (1 << (MPTSAS_LEDCTL_LED_OK2RM - 1));
12059 12199                          } else {
12060      -                                slotstatus &=
12061      -                                    ~MPI2_SEP_REQ_SLOTSTATUS_REQUEST_REMOVE;
     12200 +                                ptgt->m_led_status &=
     12201 +                                    ~(1 << (MPTSAS_LEDCTL_LED_OK2RM - 1));
12062 12202                          }
12063      -                        if (mptsas_set_led_status(mpt, ptgt, slotstatus) !=
12064      -                            DDI_SUCCESS) {
     12203 +                        if (mptsas_flush_led_status(mpt, ptgt) != DDI_SUCCESS) {
12065 12204                                  NDBG14(("mptsas_ioctl: set LED for tgt %s "
12066 12205                                      "failed %x", addr, slotstatus));
12067 12206                          }
12068 12207                          mutex_exit(&mpt->m_mutex);
12069 12208                          ndi_dc_freehdl(dcp);
12070 12209                  }
12071 12210                  goto out;
12072 12211          }
12073 12212          switch (cmd) {
     12213 +                case MPTIOCTL_GET_DISK_INFO:
     12214 +                        status = get_disk_info(mpt, data, mode);
     12215 +                        break;
     12216 +                case MPTIOCTL_LED_CONTROL:
     12217 +                        status = led_control(mpt, data, mode);
     12218 +                        break;
12074 12219                  case MPTIOCTL_UPDATE_FLASH:
12075 12220                          if (ddi_copyin((void *)data, &flashdata,
12076 12221                                  sizeof (struct mptsas_update_flash), mode)) {
12077 12222                                  status = EFAULT;
12078 12223                                  break;
12079 12224                          }
12080 12225  
12081 12226                          mutex_enter(&mpt->m_mutex);
12082 12227                          if (mptsas_update_flash(mpt,
12083 12228                              (caddr_t)(long)flashdata.PtrBuffer,
↓ open down ↓ 2440 lines elided ↑ open up ↑
14524 14669                          if (strncmp(guid, old_guid, strlen(guid)) == 0) {
14525 14670                                  /*
14526 14671                                   * Same path back online again.
14527 14672                                   */
14528 14673                                  (void) ddi_prop_free(old_guid);
14529 14674                                  if ((!MDI_PI_IS_ONLINE(*pip)) &&
14530 14675                                      (!MDI_PI_IS_STANDBY(*pip)) &&
14531 14676                                      (ptgt->m_tgt_unconfigured == 0)) {
14532 14677                                          rval = mdi_pi_online(*pip, 0);
14533 14678                                          mutex_enter(&mpt->m_mutex);
14534      -                                        (void) mptsas_set_led_status(mpt, ptgt,
14535      -                                            0);
     14679 +                                        ptgt->m_led_status = 0;
     14680 +                                        (void) mptsas_flush_led_status(mpt,
     14681 +                                            ptgt);
14536 14682                                          mutex_exit(&mpt->m_mutex);
14537 14683                                  } else {
14538 14684                                          rval = DDI_SUCCESS;
14539 14685                                  }
14540 14686                                  if (rval != DDI_SUCCESS) {
14541 14687                                          mptsas_log(mpt, CE_WARN, "path:target: "
14542 14688                                              "%x, lun:%x online failed!", target,
14543 14689                                              lun);
14544 14690                                          *pip = NULL;
14545 14691                                          *lun_dip = NULL;
↓ open down ↓ 236 lines elided ↑ open up ↑
14782 14928                          mptsas_log(mpt, CE_WARN, "mptsas driver unable to "
14783 14929                              "create phy-num property for target %d lun %d",
14784 14930                              target, lun);
14785 14931                          mdi_rtn = MDI_FAILURE;
14786 14932                          goto virt_create_done;
14787 14933                  }
14788 14934                  NDBG20(("new path:%s onlining,", MDI_PI(*pip)->pi_addr));
14789 14935                  mdi_rtn = mdi_pi_online(*pip, 0);
14790 14936                  if (mdi_rtn == MDI_SUCCESS) {
14791 14937                          mutex_enter(&mpt->m_mutex);
14792      -                        if (mptsas_set_led_status(mpt, ptgt, 0) !=
14793      -                            DDI_SUCCESS) {
     14938 +                        ptgt->m_led_status = 0;
     14939 +                        if (mptsas_flush_led_status(mpt, ptgt) != DDI_SUCCESS) {
14794 14940                                  NDBG14(("mptsas: clear LED for slot %x "
14795 14941                                      "failed", ptgt->m_slot_num));
14796 14942                          }
14797 14943                          mutex_exit(&mpt->m_mutex);
14798 14944                  }
14799 14945                  if (mdi_rtn == MDI_NOT_SUPPORTED) {
14800 14946                          mdi_rtn = MDI_FAILURE;
14801 14947                  }
14802 14948  virt_create_done:
14803 14949                  if (*pip && mdi_rtn != MDI_SUCCESS) {
↓ open down ↓ 340 lines elided ↑ open up ↑
15144 15290                   * If props were setup ok, online the lun
15145 15291                   */
15146 15292                  if (ndi_rtn == NDI_SUCCESS) {
15147 15293                          /*
15148 15294                           * Try to online the new node
15149 15295                           */
15150 15296                          ndi_rtn = ndi_devi_online(*lun_dip, NDI_ONLINE_ATTACH);
15151 15297                  }
15152 15298                  if (ndi_rtn == NDI_SUCCESS) {
15153 15299                          mutex_enter(&mpt->m_mutex);
15154      -                        if (mptsas_set_led_status(mpt, ptgt, 0) !=
15155      -                            DDI_SUCCESS) {
     15300 +                        ptgt->m_led_status = 0;
     15301 +                        if (mptsas_flush_led_status(mpt, ptgt) != DDI_SUCCESS) {
15156 15302                                  NDBG14(("mptsas: clear LED for tgt %x "
15157 15303                                      "failed", ptgt->m_slot_num));
15158 15304                          }
15159 15305                          mutex_exit(&mpt->m_mutex);
15160 15306                  }
15161 15307  
15162 15308                  /*
15163 15309                   * If success set rtn flag, else unwire alloc'd lun
15164 15310                   */
15165 15311                  if (ndi_rtn != NDI_SUCCESS) {
↓ open down ↓ 880 lines elided ↑ open up ↑
16046 16192                  return (NULL);
16047 16193          }
16048 16194          if (addr[0] == 'w') {
16049 16195                  ptgt = mptsas_wwid_to_ptgt(mpt, (int)phymask, wwn);
16050 16196          } else {
16051 16197                  ptgt = mptsas_phy_to_tgt(mpt, (int)phymask, phynum);
16052 16198          }
16053 16199          return (ptgt);
16054 16200  }
16055 16201  
16056      -#ifdef MPTSAS_GET_LED
16057 16202  static int
16058      -mptsas_get_led_status(mptsas_t *mpt, mptsas_target_t *ptgt,
16059      -    uint32_t *slotstatus)
     16203 +mptsas_flush_led_status(mptsas_t *mpt, mptsas_target_t *ptgt)
16060 16204  {
16061      -        return (mptsas_send_sep(mpt, ptgt, slotstatus,
16062      -            MPI2_SEP_REQ_ACTION_READ_STATUS));
16063      -}
16064      -#endif
16065      -static int
16066      -mptsas_set_led_status(mptsas_t *mpt, mptsas_target_t *ptgt, uint32_t slotstatus)
16067      -{
     16205 +        uint32_t slotstatus = 0;
     16206 +
     16207 +        /* Build an MPI2 Slot Status based on our view of the world */
     16208 +        if (ptgt->m_led_status & (1 << (MPTSAS_LEDCTL_LED_IDENT - 1)))
     16209 +                slotstatus |= MPI2_SEP_REQ_SLOTSTATUS_IDENTIFY_REQUEST;
     16210 +        if (ptgt->m_led_status & (1 << (MPTSAS_LEDCTL_LED_FAIL - 1)))
     16211 +                slotstatus |= MPI2_SEP_REQ_SLOTSTATUS_PREDICTED_FAULT;
     16212 +        if (ptgt->m_led_status & (1 << (MPTSAS_LEDCTL_LED_OK2RM - 1)))
     16213 +                slotstatus |= MPI2_SEP_REQ_SLOTSTATUS_REQUEST_REMOVE;
     16214 +
     16215 +        /* Write it to the controller */
16068 16216          NDBG14(("mptsas_ioctl: set LED status %x for slot %x",
16069 16217              slotstatus, ptgt->m_slot_num));
16070 16218          return (mptsas_send_sep(mpt, ptgt, &slotstatus,
16071 16219              MPI2_SEP_REQ_ACTION_WRITE_STATUS));
16072 16220  }
     16221 +
16073 16222  /*
16074 16223   *  send sep request, use enclosure/slot addressing
16075 16224   */
16076 16225  static int mptsas_send_sep(mptsas_t *mpt, mptsas_target_t *ptgt,
16077 16226      uint32_t *status, uint8_t act)
16078 16227  {
16079 16228          Mpi2SepRequest_t        req;
16080 16229          Mpi2SepReply_t          rep;
16081 16230          int                     ret;
16082 16231  
↓ open down ↓ 117 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX