]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
scsi: aacraid: Skip schedule rescan in case of kdump
authorRaghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com>
Wed, 27 Dec 2017 04:34:48 +0000 (20:34 -0800)
committerMartin K. Petersen <martin.petersen@oracle.com>
Thu, 4 Jan 2018 04:26:43 +0000 (23:26 -0500)
There is a chance of the driver to be stuck in kdump if drives start
acting up in kdump discovery process and the kernel decides to send eh
resets, which would prompt rescan to be scheduled.

Do not perform a rescan in kdump context, since we do not expect a hotplug
event during kdump and all the devices are going to go away anyway.

Signed-off-by: Raghava Aditya Renukunta <RaghavaAditya.Renukunta@microsemi.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/aacraid/commsup.c

index 706aba0ed726b43e5fdfc46acab62415a1ef2b82..f0c3e7dbf60a03c33cb7de7ce2c3fbaaa8b6ea97 100644 (file)
@@ -33,6 +33,7 @@
 
 #include <linux/kernel.h>
 #include <linux/init.h>
+#include <linux/crash_dump.h>
 #include <linux/types.h>
 #include <linux/sched.h>
 #include <linux/pci.h>
@@ -1675,7 +1676,7 @@ static int _aac_reset_adapter(struct aac_dev *aac, int forced, u8 reset_type)
         * Issue bus rescan to catch any configuration that might have
         * occurred
         */
-       if (!retval) {
+       if (!retval && !is_kdump_kernel()) {
                dev_info(&aac->pdev->dev, "Scheduling bus rescan\n");
                aac_schedule_safw_scan_worker(aac);
        }