scsi: hpsa: separate monitor events from rescan worker
authorScott Teel <scott.teel@microsemi.com>
Thu, 4 May 2017 22:51:36 +0000 (17:51 -0500)
committerMartin K. Petersen <martin.petersen@oracle.com>
Tue, 13 Jun 2017 00:48:01 +0000 (20:48 -0400)
commit3d38f00c4107cc007056db9f4ab14ecb17ed193f
treec5b145ec38a771b42a677027361420dd2dd4ddf5
parent5086435e662c7b6ada6cb5f48a1215fc6f612153
scsi: hpsa: separate monitor events from rescan worker

create new worker thread to monitor controller events
 - both the rescan and event monitor workers can cause a rescan to occur
   however for multipath we have found that we need to respond faster
   than the normal scheduled rescan interval for path fail-overs.
 - getting controller events only involves reading a register, but the
   rescan worker can obtain an updated LUN list when there is a PTRAID
   device present.
 - move common code to a separate function.
advantages:
 - detect controller events more frequently.
 - leave rescan thread interval at 30 seconds.

Reviewed-by: Scott Benesh <scott.benesh@microsemi.com>
Reviewed-by: Scott Teel <scott.teel@microsemi.com>
Reviewed-by: Kevin Barnett <kevin.barnett@microsemi.com>
Signed-off-by: Don Brace <don.brace@microsemi.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/hpsa.c
drivers/scsi/hpsa.h