From 97009a29e8c999def2d1e9ef253c226daf9541af Mon Sep 17 00:00:00 2001 From: Kei Tokunaga Date: Tue, 22 Jun 2010 19:01:51 +0900 Subject: [SCSI] mptfusion: print Doorbell register in a case of hard reset and timeout Printing Doorbell register in a case of hard reset and timeout should be useful for figuring out the state of the system. Signed-off-by: Kei Tokunaga Acked-by: "Desai, Kashyap" Signed-off-by: James Bottomley --- drivers/message/fusion/mptctl.c | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'drivers/message/fusion/mptctl.c') diff --git a/drivers/message/fusion/mptctl.c b/drivers/message/fusion/mptctl.c index 9bd89cebb5a9..40046f595f1c 100644 --- a/drivers/message/fusion/mptctl.c +++ b/drivers/message/fusion/mptctl.c @@ -954,9 +954,12 @@ retry_wait: mpt_free_msg_frame(iocp, mf); goto fwdl_out; } - if (!timeleft) + if (!timeleft) { + printk(MYIOC_s_WARN_FMT + "FW download timeout, doorbell=0x%08x\n", + iocp->name, mpt_GetIocState(iocp, 0)); mptctl_timeout_expired(iocp, mf); - else + } else goto retry_wait; goto fwdl_out; } @@ -2301,6 +2304,10 @@ retry_wait: goto done_free_mem; } if (!timeleft) { + printk(MYIOC_s_WARN_FMT + "mpt cmd timeout, doorbell=0x%08x" + " function=0x%x\n", + ioc->name, mpt_GetIocState(ioc, 0), function); if (function == MPI_FUNCTION_SCSI_TASK_MGMT) mutex_unlock(&ioc->taskmgmt_cmds.mutex); mptctl_timeout_expired(ioc, mf); @@ -2608,9 +2615,12 @@ retry_wait: mpt_free_msg_frame(ioc, mf); goto out; } - if (!timeleft) + if (!timeleft) { + printk(MYIOC_s_WARN_FMT + "HOST INFO command timeout, doorbell=0x%08x\n", + ioc->name, mpt_GetIocState(ioc, 0)); mptctl_timeout_expired(ioc, mf); - else + } else goto retry_wait; goto out; } -- cgit v1.2.3