]> Pileus Git - ~andy/linux/blobdiff - drivers/edac/edac_device.c
EDAC: Don't try to cancel workqueue when it's never setup
[~andy/linux] / 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 */