Intel 64 and IA-32 Architectures Software Developers Manual Volume 3B, System Programming Guide Part 2

Table Of Contents
Vol. 3 D-1
APPENDIX D
PROGRAMMING THE LINT0 AND LINT1 INPUTS
The following procedure describes how to program the LINT0 and LINT1 local APIC
pins on a processor after multiple processors have been booted and initialized
(as described in Appendix C, “MP Initialization For P6 Family Processors,” and
Appendix D, “Programming the LINT0 and LINT1 Inputs.” In this example, LINT0 is
programmed to be the ExtINT pin and LINT1 is programmed to be the NMI pin.
D.1 CONSTANTS
The following constants are defined:
LVT1EQU 0FEE00350H
LVT2EQU 0FEE00360H
LVT3 EQU 0FEE00370H
SVR EQU 0FEE000F0H
D.2 LINT[0:1] PINS PROGRAMMING PROCEDURE
Use the following to program the LINT[1:0] pins:
1. Mask 8259 interrupts.
2. Enable APIC via SVR (spurious vector register) if not already enabled.
MOV ESI, SVR ; address of SVR
MOV EAX, [ESI]
OR EAX, APIC_ENABLED ; set bit 8 to enable (0 on reset)
MOV [ESI], EAX
3. Program LVT1 as an ExtINT which delivers the signal to the INTR signal of all
processors cores listed in the destination as an interrupt that originated in an
externally connected interrupt controller.
MOV ESI, LVT1
MOV EAX, [ESI]
AND EAX, 0FFFE58FFH; mask off bits 8-10, 12, 14 and 16
OR EAX, 700H; Bit 16=0 for not masked, Bit 15=0 for edge
; triggered, Bit 13=0 for high active input
; polarity, Bits 8-10 are 111b for ExtINT
MOV [ESI], EAX; Write to LVT1