This bug has been copied from bug #564249 and has been proposed to be backported to 5.5 z-stream (EUS).
Note that purpose of this bz is only to fix issue described in bug 602714. This issue is fixed in 5.6 by a driver update. Separate fix is backported to this z-stream, not the full driver update.
Can you please attach the patch that has been used here?
(In reply to comment #5) > Can you please attach the patch that has been used here? Sorry, we don't have the patch yet.
Created attachment 441053 [details] Update the megaraid sas driver to rhel5.5.z Tomas, Attached is the patch for megaraid sas driver for rhel5.5.z
Tomas, Let me know if you are facing the issues for this patch. Thanks, Bo Yang
(In reply to comment #7) > Attached is the patch for megaraid sas driver for rhel5.5.z Thanks, I'll look into it.
Hi Bo, I looked at the differencies between 5.5.z and 5.6 and would like you to clarify some points: megasas_check_reset_gen2(struct megasas_instance *instance, struct megasas_register_set __iomem * regs) { + if (instance->adprecovery != MEGASAS_HBA_OPERATIONAL) { + return 1; + } 1.This is missing in 5.6 should it be added? I'll change the sysfs_max_sectors_read function so it corresponds to what is in 5.6 myself and let you verify that. @@ -3033,7 +3055,6 @@ megasas_get_pd_list(struct megasas_insta dcmd->timeout = 0; - dcmd->pad_0 = 0; dcmd->data_xfer_len = MEGASAS_MAX_PD * sizeof(struct MR_PD_LIST); 2.This is missing in 5.5,z should it be added? @@ -3142,7 +3159,7 @@ megasas_get_ld_list(struct megasas_insta - if ( (ret == 0) && (ci->ldCount <= (MAX_LOGICAL_DRIVES))){ + if ( (ret == 0) && (ci->ldCount < (MAX_LOGICAL_DRIVES))){ 3.Which version is wrong? 4.In 5.6 we have scsi_host_put(host); in megasas_suspend this seems to be wrong should it be removed? @@ -4174,21 +4190,12 @@ megasas_suspend(struct pci_dev *pdev, pm - scsi_host_put(host); pci_save_state(pdev); 5.Then there is a lot of changes in cancel_delayed_work(&ev->hotplug_work); which is missing in 5.5.z @@ -3933,7 +3950,6 @@ megasas_probe_one(struct pci_dev *pdev, instance->flag_ieee = 0; - instance->ev = NULL; instance->issuepend_done = 1; @@ -4174,21 +4190,12 @@ megasas_suspend(struct pci_dev *pdev, pm megasas_shutdown_controller(instance, MR_DCMD_HIBERNATE_SHUTDOWN); - /* cancel the delayed work if this work still in queue */ - if (instance->ev != NULL) { - struct megasas_aen_event *ev = instance->ev; - cancel_delayed_work(&ev->hotplug_work); - flush_scheduled_work(); - instance->ev = NULL; - } - tasklet_kill(&instance->isr_tasklet); @@ -4327,14 +4329,6 @@ static void __devexit megasas_detach_one megasas_shutdown_controller(instance, MR_DCMD_CTRL_SHUTDOWN); - /* cancel the delayed work if this work still in queue*/ - if (instance->ev != NULL) { - struct megasas_aen_event *ev = instance->ev; - cancel_delayed_work(&ev->hotplug_work); - flush_scheduled_work(); - instance->ev = NULL; - } - tasklet_kill(&instance->isr_tasklet); @@ -5007,7 +4989,6 @@ megasas_aen_polling(void *arg) return; } - instance->ev = NULL; host = instance->host; @@ -5007,7 +4989,6 @@ megasas_aen_polling(void *arg) } - instance->ev = NULL; host = instance->host; 6.This is again missing in 5.5.z - which version is ok? @@ -4261,11 +4268,6 @@ megasas_resume(struct pci_dev *pdev) /* - * Store instance in PCI softstate - */ - pci_set_drvdata(pdev, instance); -
Bo, thanks for posting the 4.9 version. Please answer the question here, as some of them seems to apply also for the 4.9 version. Thanks, Tomas
Bo, any news here?
Tomas, 1. megasas_check_reset_gen2(struct megasas_instance *instance, struct megasas_register_set __iomem * regs) { + if (instance->adprecovery != MEGASAS_HBA_OPERATIONAL) { + return 1; + } 1.This is missing in 5.6 should it be added? --->this is needed. It was fixed in later version (4.32). 2. @@ -3033,7 +3055,6 @@ megasas_get_pd_list(struct megasas_insta dcmd->timeout = 0; - dcmd->pad_0 = 0; dcmd->data_xfer_len = MEGASAS_MAX_PD * sizeof(struct MR_PD_LIST); --->we see the issue in VMWare esx4.xx, but it is not seeing in Linux. it is OK if not have this. 3. 2.This is missing in 5.5,z should it be added? @@ -3142,7 +3159,7 @@ megasas_get_ld_list(struct megasas_insta - if ( (ret == 0) && (ci->ldCount <= (MAX_LOGICAL_DRIVES))){ + if ( (ret == 0) && (ci->ldCount < (MAX_LOGICAL_DRIVES))){ ---> - if ( (ret == 0) && (ci->ldCount <= (MAX_LOGICAL_DRIVES))){ is the correct one, but I only apply the OCR changes based on the base, so it missed. all items 4, 5 and 6 was not related to OCR. So they are not in rhel5.5z as base doesn't have.
Bo, I just posted this for internal review. Next time please consider running checkpatch.pl against your patches and correct the coding style issues. There is a lot of them. &checkpatch.pl your.patch .... total: 365 errors, 155 warnings, 2828 lines checked
in kernel 2.6.18-194.20.1.el5 linux-2.6-scsi-megaraid_sas-fix-physical-disk-handling.patch
5.5.z bits are available for testing. Please update the bugzilla with test results. http://people.redhat.com/~kzhang/kernel-2.6.18-194.25.1.el5.test2.i686.rpm http://people.redhat.com/kzhang/kernel-2.6.18-194.25.1.el5.test2.x86_64.rpm http://people.redhat.com/~kzhang/kernel-2.6.18-194.25.1.el5.test2.ia64.rpm
Hi, any updates? We expect to get feedback before Nov. 8
Confirmed patch linux-2.6-scsi-megaraid_sas-fix-physical-disk-handling.patch is applied in 2.6.18-194.26.1.el5 kernel correctly. Set SanityOnly verified
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHSA-2010-0839.html
Technical note added. If any revisions are required, please edit the "Technical Notes" field accordingly. All revisions will be proofread by the Engineering Content Services team. New Contents: A bug was found in the way the megaraid_sas driver (for SAS based RAID controllers) handled physical disks and management IOCTLs (Input/Output Control). All physical disks were exported to the disk layer, allowing an oops in megasas_complete_cmd_dpc() when completing the IOCTL command if a timeout occurred. One possible trigger for this bug was running mkfs. This update resolves this issue by updating the megaraid_sas driver to version 4.31.