Skip to content

Commit ecc479e

Browse files
Raghava Aditya Renukuntamartinkpetersen
authored andcommitted
aacraid: Set correct msix count for EEH recovery
During EEH recovery number of online CPU's might change thereby changing the number of MSIx vectors. Since each fib is allocated to a vector, changes in the number of vectors causes fib to be sent thru invalid vectors.In addition the correct number of MSIx vectors is not updated in the INIT struct sent to the controller, when it is reinitialized. Fixed by reassigning vectors to fibs based on the updated number of MSIx vectors and updating the INIT structure before sending to controller. Fixes: MSI-X vector calculation for suspend/resume Cc: [email protected] Signed-off-by: Raghava Aditya Renukunta <[email protected]> Reviewed-by: Shane Seymour <[email protected]> Reviewed-by: Johannes Thumshirn <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
1 parent f88fa79 commit ecc479e

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

drivers/scsi/aacraid/linit.c

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1409,8 +1409,18 @@ static int aac_acquire_resources(struct aac_dev *dev)
14091409

14101410
aac_adapter_enable_int(dev);
14111411

1412-
if (!dev->sync_mode)
1412+
/*max msix may change after EEH
1413+
* Re-assign vectors to fibs
1414+
*/
1415+
aac_fib_vector_assign(dev);
1416+
1417+
if (!dev->sync_mode) {
1418+
/* After EEH recovery or suspend resume, max_msix count
1419+
* may change, therfore updating in init as well.
1420+
*/
14131421
aac_adapter_start(dev);
1422+
dev->init->Sa_MSIXVectors = cpu_to_le32(dev->max_msix);
1423+
}
14141424
return 0;
14151425

14161426
error_iounmap:

0 commit comments

Comments
 (0)