From f41f1d994e0e2e0fab29c6f3f9c77350f1769166 Mon Sep 17 00:00:00 2001 From: Gabriel Krisman Bertazi Date: Tue, 3 Nov 2015 16:26:06 -0200 Subject: ipr: Add delay to ensure coherent dumps. Add a holding pattern prior to collecting dump data, to wait for the IOA indication that the Mailbox register is stable and won't change without an explicit reset. This ensures we'll be collecting meaningful dump data, even when dumping right after an adapter reset. In the event of a timeout, we still force the dump, since a partial dump still might be useful. Signed-off-by: Gabriel Krisman Bertazi Acked-by: Brian King Reviewed-by: Wen Xiong Signed-off-by: Martin K. Petersen --- drivers/scsi/ipr.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'drivers/scsi/ipr.h') diff --git a/drivers/scsi/ipr.h b/drivers/scsi/ipr.h index e4fb17a58649..69257c4540a9 100644 --- a/drivers/scsi/ipr.h +++ b/drivers/scsi/ipr.h @@ -279,6 +279,9 @@ #define IPR_IPL_INIT_STAGE_TIME_MASK 0x0000ffff #define IPR_PCII_IPL_STAGE_CHANGE (0x80000000 >> 0) +#define IPR_PCII_MAILBOX_STABLE (0x80000000 >> 4) +#define IPR_WAIT_FOR_MAILBOX (2 * HZ) + #define IPR_PCII_IOA_TRANS_TO_OPER (0x80000000 >> 0) #define IPR_PCII_IOARCB_XFER_FAILED (0x80000000 >> 3) #define IPR_PCII_IOA_UNIT_CHECKED (0x80000000 >> 4) -- cgit v1.2.3