函数源码 |
Source File:arch\x86\kernel\reboot.c |
Create Date:2022-07-27 09:18:29 |
首页 | Copyright©Brick |
674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 | void native_machine_shutdown( void ) { /* Stop the cpus and apics */ #ifdef CONFIG_X86_IO_APIC /* * Disabling IO APIC before local APIC is a workaround for * erratum AVR31 in "Intel Atom Processor C2000 Product Family * Specification Update". In this situation, interrupts that target * a Logical Processor whose Local APIC is either in the process of * being hardware disabled or software disabled are neither delivered * nor discarded. When this erratum occurs, the processor may hang. * * Even without the erratum, it still makes sense to quiet IO APIC * before disabling Local APIC. */ clear_IO_APIC(); #endif #ifdef CONFIG_SMP /* * Stop all of the others. Also disable the local irq to * not receive the per-cpu timer interrupt which may trigger * scheduler's load balance. */ local_irq_disable(); stop_other_cpus(); #endif lapic_shutdown(); restore_boot_irq_mode(); #ifdef CONFIG_HPET_TIMER hpet_disable(); #endif #ifdef CONFIG_X86_64 x86_platform.iommu_shutdown(); #endif } |