]> Git Repo - linux.git/commitdiff
EDAC/igen6: Fix the issue of no error events
authorQiuxu Zhuo <[email protected]>
Tue, 25 Jul 2023 08:04:27 +0000 (16:04 +0800)
committerTony Luck <[email protected]>
Wed, 2 Aug 2023 20:09:56 +0000 (13:09 -0700)
Current igen6_edac checks for pending errors before the registration
of the error handler. However, there is a possibility that the error
occurs during the registration process, leading to unhandled pending
errors and no future error events. This issue can be reproduced by
repeatedly injecting errors during the loading of the igen6_edac.

Fix this issue by moving the pending error handler after the registration
of the error handler, ensuring that no pending errors are left unhandled.

Fixes: 10590a9d4f23 ("EDAC/igen6: Add EDAC driver for Intel client SoCs using IBECC")
Reported-by: Ee Wey Lim <[email protected]>
Tested-by: Ee Wey Lim <[email protected]>
Signed-off-by: Qiuxu Zhuo <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
drivers/edac/igen6_edac.c

index 544dd19072eab6dff7b38858209103c222d70e05..1a18693294db48dd5b37761f5b1f1a7368a68f51 100644 (file)
@@ -27,7 +27,7 @@
 #include "edac_mc.h"
 #include "edac_module.h"
 
-#define IGEN6_REVISION "v2.5"
+#define IGEN6_REVISION "v2.5.1"
 
 #define EDAC_MOD_STR   "igen6_edac"
 #define IGEN6_NMI_NAME "igen6_ibecc"
@@ -1216,9 +1216,6 @@ static int igen6_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
        INIT_WORK(&ecclog_work, ecclog_work_cb);
        init_irq_work(&ecclog_irq_work, ecclog_irq_work_cb);
 
-       /* Check if any pending errors before registering the NMI handler */
-       ecclog_handler();
-
        rc = register_err_handler();
        if (rc)
                goto fail3;
@@ -1230,6 +1227,9 @@ static int igen6_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
                goto fail4;
        }
 
+       /* Check if any pending errors before/during the registration of the error handler */
+       ecclog_handler();
+
        igen6_debug_setup();
        return 0;
 fail4:
This page took 0.066427 seconds and 4 git commands to generate.