scsi: mpi3mr: Graceful handling of surprise removal of PCIe HBA
authorSreekanth Reddy <sreekanth.reddy@broadcom.com>
Mon, 12 Sep 2022 13:57:37 +0000 (19:27 +0530)
committerMartin K. Petersen <martin.petersen@oracle.com>
Sun, 25 Sep 2022 17:49:52 +0000 (13:49 -0400)
commitf2a79d2030ad9055e58f5b617f655fa5e270a57c
tree1cfb76c86ad0c55c347a72e2391ba61e6495af56
parent7f9f953d537a7c8362ed6adafd25ef8deb548756
scsi: mpi3mr: Graceful handling of surprise removal of PCIe HBA

Implement graceful handling of surprise or orderly removal of PCIe HBA:

 - Detect a hot removal of the controller at certain critical places in the
   driver. Early detection will help to reduce the time taken for cleaning
   up the hot-removed controller at the driver level.

 - Poll the status of the port enable issued after reset once every 5
   seconds to avoid a long delay in detecting unavailable controller.

Link: https://lore.kernel.org/r/20220912135742.11764-5-sreekanth.reddy@broadcom.com
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Sreekanth Reddy <sreekanth.reddy@broadcom.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/mpi3mr/mpi3mr.h
drivers/scsi/mpi3mr/mpi3mr_fw.c
drivers/scsi/mpi3mr/mpi3mr_os.c