hc
2024-01-03 2f7c68cb55ecb7331f2381deb497c27155f32faf
kernel/drivers/acpi/apei/ghes.c
....@@ -1457,33 +1457,35 @@
14571457 .remove = ghes_remove,
14581458 };
14591459
1460
-static int __init ghes_init(void)
1460
+void __init ghes_init(void)
14611461 {
14621462 int rc;
14631463
1464
+ sdei_init();
1465
+
14641466 if (acpi_disabled)
1465
- return -ENODEV;
1467
+ return;
14661468
14671469 switch (hest_disable) {
14681470 case HEST_NOT_FOUND:
1469
- return -ENODEV;
1471
+ return;
14701472 case HEST_DISABLED:
14711473 pr_info(GHES_PFX "HEST is not enabled!\n");
1472
- return -EINVAL;
1474
+ return;
14731475 default:
14741476 break;
14751477 }
14761478
14771479 if (ghes_disable) {
14781480 pr_info(GHES_PFX "GHES is not enabled!\n");
1479
- return -EINVAL;
1481
+ return;
14801482 }
14811483
14821484 ghes_nmi_init_cxt();
14831485
14841486 rc = platform_driver_register(&ghes_platform_driver);
14851487 if (rc)
1486
- goto err;
1488
+ return;
14871489
14881490 rc = apei_osc_setup();
14891491 if (rc == 0 && osc_sb_apei_support_acked)
....@@ -1494,9 +1496,4 @@
14941496 pr_info(GHES_PFX "APEI firmware first mode is enabled by APEI bit.\n");
14951497 else
14961498 pr_info(GHES_PFX "Failed to enable APEI firmware first mode.\n");
1497
-
1498
- return 0;
1499
-err:
1500
- return rc;
15011499 }
1502
-device_initcall(ghes_init);