Commit 6431f5d7 authored by Sumit.Saxena@lsi.com's avatar Sumit.Saxena@lsi.com Committed by James Bottomley

[SCSI] megaraid_sas: megaraid_sas driver init fails in kdump kernel

Problem: When Hardware IOMMU is on, megaraid_sas driver initialization fails
in kdump kernel with LSI MegaRAID controller(device id-0x73).

Actually this issue needs fix in firmware, but for firmware running in field,
this driver fix is proposed to resolve the issue.  At firmware initialization
time, if firmware does not come to ready state, driver will reset the adapter
and retry for firmware transition to ready state unconditionally(not only
executed for kdump kernel).
Signed-off-by: default avatarSumit Saxena <sumit.saxena@lsi.com>
Signed-off-by: default avatarKashyap Desai <kashyap.desai@lsi.com>
Cc: stable@vger.kernel.org
Signed-off-by: default avatarJames Bottomley <JBottomley@Parallels.com>
parent 36f571e9
...@@ -3547,11 +3547,21 @@ static int megasas_init_fw(struct megasas_instance *instance) ...@@ -3547,11 +3547,21 @@ static int megasas_init_fw(struct megasas_instance *instance)
break; break;
} }
/* if (megasas_transition_to_ready(instance, 0)) {
* We expect the FW state to be READY atomic_set(&instance->fw_reset_no_pci_access, 1);
*/ instance->instancet->adp_reset
if (megasas_transition_to_ready(instance, 0)) (instance, instance->reg_set);
goto fail_ready_state; atomic_set(&instance->fw_reset_no_pci_access, 0);
dev_info(&instance->pdev->dev,
"megasas: FW restarted successfully from %s!\n",
__func__);
/*waitting for about 30 second before retry*/
ssleep(30);
if (megasas_transition_to_ready(instance, 0))
goto fail_ready_state;
}
/* /*
* MSI-X host index 0 is common for all adapter. * MSI-X host index 0 is common for all adapter.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment