提交 fbaa9aa4 编写于 作者: S Sreekanth Reddy 提交者: Martin K. Petersen

scsi: mpi3mr: Don't reset IOC if cmnds flush with reset status

Don't issue the soft reset if internal commands are flushed out with reset
status. Soft reset needs to be issued only if commands are really timed
out.

Link: https://lore.kernel.org/r/20211220141159.16117-4-sreekanth.reddy@broadcom.comSigned-off-by: NSreekanth Reddy <sreekanth.reddy@broadcom.com>
Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
上级 a83ec831
...@@ -1947,8 +1947,9 @@ static int mpi3mr_sync_timestamp(struct mpi3mr_ioc *mrioc) ...@@ -1947,8 +1947,9 @@ static int mpi3mr_sync_timestamp(struct mpi3mr_ioc *mrioc)
if (!(mrioc->init_cmds.state & MPI3MR_CMD_COMPLETE)) { if (!(mrioc->init_cmds.state & MPI3MR_CMD_COMPLETE)) {
ioc_err(mrioc, "Issue IOUCTL time_stamp: command timed out\n"); ioc_err(mrioc, "Issue IOUCTL time_stamp: command timed out\n");
mrioc->init_cmds.is_waiting = 0; mrioc->init_cmds.is_waiting = 0;
mpi3mr_soft_reset_handler(mrioc, if (!(mrioc->init_cmds.state & MPI3MR_CMD_RESET))
MPI3MR_RESET_FROM_TSU_TIMEOUT, 1); mpi3mr_soft_reset_handler(mrioc,
MPI3MR_RESET_FROM_TSU_TIMEOUT, 1);
retval = -1; retval = -1;
goto out_unlock; goto out_unlock;
} }
...@@ -2827,8 +2828,9 @@ int mpi3mr_send_event_ack(struct mpi3mr_ioc *mrioc, u8 event, ...@@ -2827,8 +2828,9 @@ int mpi3mr_send_event_ack(struct mpi3mr_ioc *mrioc, u8 event,
(MPI3MR_INTADMCMD_TIMEOUT * HZ)); (MPI3MR_INTADMCMD_TIMEOUT * HZ));
if (!(mrioc->init_cmds.state & MPI3MR_CMD_COMPLETE)) { if (!(mrioc->init_cmds.state & MPI3MR_CMD_COMPLETE)) {
ioc_err(mrioc, "Issue EvtNotify: command timed out\n"); ioc_err(mrioc, "Issue EvtNotify: command timed out\n");
mpi3mr_soft_reset_handler(mrioc, if (!(mrioc->init_cmds.state & MPI3MR_CMD_RESET))
MPI3MR_RESET_FROM_EVTACK_TIMEOUT, 1); mpi3mr_soft_reset_handler(mrioc,
MPI3MR_RESET_FROM_EVTACK_TIMEOUT, 1);
retval = -1; retval = -1;
goto out_unlock; goto out_unlock;
} }
......
...@@ -2659,8 +2659,9 @@ static int mpi3mr_issue_tm(struct mpi3mr_ioc *mrioc, u8 tm_type, ...@@ -2659,8 +2659,9 @@ static int mpi3mr_issue_tm(struct mpi3mr_ioc *mrioc, u8 tm_type,
ioc_err(mrioc, "%s :Issue TM: command timed out\n", __func__); ioc_err(mrioc, "%s :Issue TM: command timed out\n", __func__);
drv_cmd->is_waiting = 0; drv_cmd->is_waiting = 0;
retval = -1; retval = -1;
mpi3mr_soft_reset_handler(mrioc, if (!(drv_cmd->state & MPI3MR_CMD_RESET))
MPI3MR_RESET_FROM_TM_TIMEOUT, 1); mpi3mr_soft_reset_handler(mrioc,
MPI3MR_RESET_FROM_TM_TIMEOUT, 1);
goto out_unlock; goto out_unlock;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册