Merge tag 'dlm-3.15' of git://git.kernel.org/pub/scm/linux/kernel/git/teigland/linux-dlm
[firefly-linux-kernel-4.4.55.git] / drivers / edac / edac_device.c
index 102674346035e13bc28d6f3f001ea0d4a5e57e29..592af5f0cf391d292e05fd5c3a94b5589c7cb684 100644 (file)
@@ -437,6 +437,9 @@ void edac_device_workq_teardown(struct edac_device_ctl_info *edac_dev)
 {
        int status;
 
+       if (!edac_dev->edac_check)
+               return;
+
        status = cancel_delayed_work(&edac_dev->work);
        if (status == 0) {
                /* workq instance might be running, wait for it */