scsi: cxlflash: Improve EEH recovery time
authorMatthew R. Ochs <mrochs@linux.vnet.ibm.com>
Fri, 2 Sep 2016 20:40:03 +0000 (15:40 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 8 May 2017 05:46:02 +0000 (07:46 +0200)
commit6f81dea4037c878e27e3cb25cabc85c2f897fdfd
tree8fbac59f28a2541667968c455c23f716f28e8874
parent24d17d7853fa64189d32ac6416c6cacc3fed449c
scsi: cxlflash: Improve EEH recovery time

commit 05dab43230fdc0d14ca885b473a2740fe017ecb1 upstream.

When an EEH occurs during device initialization, the port timeout logic
can cause excessive delays as MMIO reads will fail. Depending on where
they are experienced, these delays can lead to a prolonged reset,
causing an unnecessary triggering of other timeout logic in the SCSI
stack or user applications.

To expedite recovery, the port timeout logic is updated to decay the
timeout at a much faster rate when in the presence of a likely EEH
frozen event.

Signed-off-by: Matthew R. Ochs <mrochs@linux.vnet.ibm.com>
Acked-by: Uma Krishnan <ukrishn@linux.vnet.ibm.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Cc: Sumit Semwal <sumit.semwal@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/scsi/cxlflash/main.c