amd64_edac: fix ecc_enable_override handling
authorBorislav Petkov <borislav.petkov@amd.com>
Mon, 22 Jun 2009 17:42:24 +0000 (19:42 +0200)
committerBorislav Petkov <borislav.petkov@amd.com>
Fri, 26 Jun 2009 11:06:41 +0000 (13:06 +0200)
amd64_check_ecc_enabled() returns non-zero status when ECC
checking/correcting is disabled and this fails further loading of the
driver even when 'ecc_enable_override' boot param is used.

Fix that by clearing return status in that case.

Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
drivers/edac/amd64_edac.c

index 3b76605330e972b9ece83a1b5702be962991d4da..8497963a61f6536e123739561a6bae4964b9f49a 100644 (file)
@@ -2966,7 +2966,12 @@ static int amd64_check_ecc_enabled(struct amd64_pvt *pvt)
                                "    Use of the override can cause "
                                "unknown side effects.\n");
                        ret = -ENODEV;
-               }
+               } else
+                       /*
+                        * enable further driver loading if ECC enable is
+                        * overridden.
+                        */
+                       ret = 0;
        } else {
                amd64_printk(KERN_INFO,
                        "ECC is enabled by BIOS, Proceeding "