| Function report | 
| Source Code: arch\x86\kernel\reboot.c | Create Date:2022-07-28 08:18:35 | 
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick | 
| home page | Tree | 
| Annotation kernel can get tool activity | Download SCCT | Chinese | 
Name:To the best of our knowledge Windows compatible x86 hardware expects* the following on reboot:* 1) If the FADT has the ACPI reboot register flag set, try it* 2) If still alive, write to the keyboard controller* 3) If still alive, write to the ACPI reboot
Proto:static void native_machine_emergency_restart(void)
Type:void
Parameter:Nothing
| 588 | attempt = 0 | 
| 589 | orig_reboot_type = reboot_type | 
| 598 | mode = If reboot_mode == REBOOT_WARM Then 0x1234 Else 0 | 
| 605 | If efi_capsule_pending(NULL) Then | 
| 606 | pr_info("EFI capsule is pending, forcing EFI reboot.\n") | 
| 607 | reboot_type = BOOT_EFI | 
| 610 | cycle | 
| 613 | Case (reboot_type) == BOOT_ACPI | 
| 618 | Case (reboot_type) == BOOT_KBD | 
| 619 | mach_reboot_fixups() | 
| 622 | kb_wait() | 
| 624 | Basic port I/O | 
| 627 | If attempt == 0 && orig_reboot_type == BOOT_ACPI Then | 
| 628 | attempt = 1 | 
| 629 | reboot_type = BOOT_ACPI | 
| 630 | Else | 
| 631 | reboot_type = BOOT_EFI | 
| 633 | Break | 
| 635 | Case (reboot_type) == BOOT_EFI | 
| 640 | Case (reboot_type) == BOOT_BIOS | 
| 644 | reboot_type = BOOT_CF9_SAFE | 
| 645 | Break | 
| 647 | Case (reboot_type) == BOOT_CF9_FORCE | 
| 651 | Case (reboot_type) == BOOT_CF9_SAFE | 
| 653 | reboot_code = If reboot_mode == REBOOT_WARM Then 0x06 Else 0x0E | 
| 654 | cf9 = inb(0xcf9) & ~reboot_code | 
| 655 | Basic port I/O | 
| 658 | Basic port I/O | 
| 661 | reboot_type = BOOT_TRIPLE | 
| 662 | Break | 
| 664 | Case (reboot_type) == BOOT_TRIPLE | 
| Source code conversion tool public plug-in interface | X | 
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |