.. | .. |
---|
1457 | 1457 | .remove = ghes_remove, |
---|
1458 | 1458 | }; |
---|
1459 | 1459 | |
---|
1460 | | -static int __init ghes_init(void) |
---|
| 1460 | +void __init ghes_init(void) |
---|
1461 | 1461 | { |
---|
1462 | 1462 | int rc; |
---|
1463 | 1463 | |
---|
| 1464 | + sdei_init(); |
---|
| 1465 | + |
---|
1464 | 1466 | if (acpi_disabled) |
---|
1465 | | - return -ENODEV; |
---|
| 1467 | + return; |
---|
1466 | 1468 | |
---|
1467 | 1469 | switch (hest_disable) { |
---|
1468 | 1470 | case HEST_NOT_FOUND: |
---|
1469 | | - return -ENODEV; |
---|
| 1471 | + return; |
---|
1470 | 1472 | case HEST_DISABLED: |
---|
1471 | 1473 | pr_info(GHES_PFX "HEST is not enabled!\n"); |
---|
1472 | | - return -EINVAL; |
---|
| 1474 | + return; |
---|
1473 | 1475 | default: |
---|
1474 | 1476 | break; |
---|
1475 | 1477 | } |
---|
1476 | 1478 | |
---|
1477 | 1479 | if (ghes_disable) { |
---|
1478 | 1480 | pr_info(GHES_PFX "GHES is not enabled!\n"); |
---|
1479 | | - return -EINVAL; |
---|
| 1481 | + return; |
---|
1480 | 1482 | } |
---|
1481 | 1483 | |
---|
1482 | 1484 | ghes_nmi_init_cxt(); |
---|
1483 | 1485 | |
---|
1484 | 1486 | rc = platform_driver_register(&ghes_platform_driver); |
---|
1485 | 1487 | if (rc) |
---|
1486 | | - goto err; |
---|
| 1488 | + return; |
---|
1487 | 1489 | |
---|
1488 | 1490 | rc = apei_osc_setup(); |
---|
1489 | 1491 | if (rc == 0 && osc_sb_apei_support_acked) |
---|
.. | .. |
---|
1494 | 1496 | pr_info(GHES_PFX "APEI firmware first mode is enabled by APEI bit.\n"); |
---|
1495 | 1497 | else |
---|
1496 | 1498 | pr_info(GHES_PFX "Failed to enable APEI firmware first mode.\n"); |
---|
1497 | | - |
---|
1498 | | - return 0; |
---|
1499 | | -err: |
---|
1500 | | - return rc; |
---|
1501 | 1499 | } |
---|
1502 | | -device_initcall(ghes_init); |
---|