Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

[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: Sumit Saxena <sumit.saxena@lsi.com>
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Cc: stable@vger.kernel.org
Signed-off-by: James Bottomley <JBottomley@Parallels.com>

authored by

Sumit.Saxena@lsi.com and committed by
James Bottomley
6431f5d7 36f571e9

+15 -5
+15 -5
drivers/scsi/megaraid/megaraid_sas_base.c
··· 3547 3547 break; 3548 3548 } 3549 3549 3550 - /* 3551 - * We expect the FW state to be READY 3552 - */ 3553 - if (megasas_transition_to_ready(instance, 0)) 3554 - goto fail_ready_state; 3550 + if (megasas_transition_to_ready(instance, 0)) { 3551 + atomic_set(&instance->fw_reset_no_pci_access, 1); 3552 + instance->instancet->adp_reset 3553 + (instance, instance->reg_set); 3554 + atomic_set(&instance->fw_reset_no_pci_access, 0); 3555 + dev_info(&instance->pdev->dev, 3556 + "megasas: FW restarted successfully from %s!\n", 3557 + __func__); 3558 + 3559 + /*waitting for about 30 second before retry*/ 3560 + ssleep(30); 3561 + 3562 + if (megasas_transition_to_ready(instance, 0)) 3563 + goto fail_ready_state; 3564 + } 3555 3565 3556 3566 /* 3557 3567 * MSI-X host index 0 is common for all adapter.