Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\kernel\apic\apic.c Create Date:2022-07-28 08:27:00
Last Modify:2020-03-16 21:21:31 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:lear_local_APIC - shutdown the local APIC* This is called, when a CPU is disabled and before rebooting, so the state of* the local APIC has no dangling leftovers. Also used to cleanout any BIOS* leftovers during boot.

Proto:void clear_local_APIC(void)

Type:void

Parameter:Nothing

1173  If Not x2apic_mode && Not apic_phys Then Return
1176  maxlvt = lapic_get_maxlvt - get the maximum number of local vector table entries
1181  If maxlvt >= 3 Then
1182  v = ERROR_APIC_VECTOR
1183  apic_write(APIC_LVTERR, v | APIC_LVT_MASKED)
1189  v = apic_read(APIC_LVTT)
1190  apic_write(APIC_LVTT, v | APIC_LVT_MASKED)
1191  v = apic_read(APIC_LVT0)
1192  apic_write(APIC_LVT0, v | APIC_LVT_MASKED)
1193  v = apic_read(APIC_LVT1)
1194  apic_write(APIC_LVT1, v | APIC_LVT_MASKED)
1195  If maxlvt >= 4 Then
1196  v = apic_read(APIC_LVTPC)
1197  apic_write(APIC_LVTPC, v | APIC_LVT_MASKED)
1218  apic_write(APIC_LVTT, APIC_LVT_MASKED)
1219  apic_write(APIC_LVT0, APIC_LVT_MASKED)
1220  apic_write(APIC_LVT1, APIC_LVT_MASKED)
1221  If maxlvt >= 3 Then apic_write(APIC_LVTERR, APIC_LVT_MASKED)
1223  If maxlvt >= 4 Then apic_write(APIC_LVTPC, APIC_LVT_MASKED)
1227  If Check, if the APIC is integrated or a separate chip Then
1228  If maxlvt > 3 Then apic_write(APIC_ESR, 0)
1231  apic_read(APIC_ESR)
Caller
NameDescribe
apic_soft_disableapic_soft_disable - Clears and software disables the local APIC on hotplug* Contrary to disable_local_APIC() this does not touch the enable bit in* MSR_IA32_APICBASE
lapic_shutdownIf Linux enabled the LAPIC against the BIOS default disable it down before* re-entering the BIOS on shutdown. Otherwise the BIOS may get confused and* not power-off. Additionally clear all LVT entries before disable_local_APIC
init_bsp_APICAn initial setup of the virtual wire mode.
connect_bsp_APICect_bsp_APIC - attach the APIC to the interrupt system