Print this page
First attempt at pulling 4310 fix from Andy Giles tree

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/io/scsi/adapters/mpt_sas/mptsas_impl.c
          +++ new/usr/src/uts/common/io/scsi/adapters/mpt_sas/mptsas_impl.c
↓ open down ↓ 1188 lines elided ↑ open up ↑
1189 1189                  }
1190 1190                  mutex_enter(&mpt->m_mutex);
1191 1191          }
1192 1192  
1193 1193          /*
1194 1194           * clear the TM slot before returning
1195 1195           */
1196 1196          slots->m_slot[MPTSAS_TM_SLOT(mpt)] = NULL;
1197 1197  
1198 1198          /*
1199      -         * If we lost our task management command
1200      -         * we need to reset the ioc
     1199 +         * If we lost our task management command we need to reset the ioc
     1200 +         * but we can't do it here as it's most likely we were called from
     1201 +         * the taskq that mptsas_restart_ioc()->mptsas_flush_hba() needs to
     1202 +         * wait for. So set a flag for mptsas_watch().
1201 1203           */
1202 1204          if (rval == FALSE) {
1203 1205                  mptsas_log(mpt, CE_WARN, "mptsas_ioc_task_management failed "
1204      -                    "try to reset ioc to recovery!");
1205      -                mpt->m_softstate &= ~MPTSAS_SS_MSG_UNIT_RESET;
1206      -                if (mptsas_restart_ioc(mpt)) {
1207      -                        mptsas_log(mpt, CE_WARN, "mptsas_restart_ioc failed");
1208      -                        rval = FAILED;
1209      -                }
     1206 +                    "schedule reset in watch!");
     1207 +                mpt->m_softstate |= MPTSAS_SS_RESET_INWATCH;
1210 1208          }
1211      -
     1209 +        
1212 1210          return (rval);
1213 1211  }
1214 1212  
1215 1213  /*
1216 1214   * Complete firmware download frame for v2.0 cards.
1217 1215   */
1218 1216  static void
1219 1217  mptsas_uflash2(pMpi2FWDownloadRequest fwdownload,
1220 1218      ddi_acc_handle_t acc_hdl, uint32_t size, uint8_t type,
1221 1219      ddi_dma_cookie_t flsh_cookie)
↓ open down ↓ 1579 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX