Home | History | Annotate | Download | only in X64
      1 ## @file
      2 #  Interrupt Redirection Template
      3 #
      4 # Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>
      5 #
      6 # This program and the accompanying materials
      7 # are licensed and made available under the terms and conditions
      8 # of the BSD License which accompanies this distribution.  The
      9 # full text of the license may be found at
     10 # http://opensource.org/licenses/bsd-license.php
     11 #
     12 # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     13 # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
     14 #
     15 ##
     16 
     17 #text SEGMENT
     18 
     19 
     20 #----------------------------------------------------------------------------
     21 # Procedure:    InterruptRedirectionTemplate: Redirects interrupts 0x68-0x6F
     22 #
     23 # Input:        None
     24 #
     25 # Output:       None
     26 #
     27 # Prototype:    VOID
     28 #               InterruptRedirectionTemplate (
     29 #                                VOID
     30 #                                );
     31 #
     32 # Saves:        None
     33 #
     34 # Modified:     None
     35 #
     36 # Description:  Contains the code that is copied into low memory (below 640K).
     37 #               This code reflects interrupts 0x68-0x6f to interrupts 0x08-0x0f.
     38 #               This template must be copied into low memory, and the IDT entries
     39 #               0x68-0x6F must be point to the low memory copy of this code.  Each
     40 #               entry is 4 bytes long, so IDT entries 0x68-0x6F can be easily
     41 #               computed.
     42 #
     43 #----------------------------------------------------------------------------
     44 
     45 ASM_GLOBAL ASM_PFX(InterruptRedirectionTemplate)
     46 ASM_PFX(InterruptRedirectionTemplate):
     47   int     $0x08
     48   .byte      0x0cf          # IRET
     49   nop
     50   int     $0x09
     51   .byte      0x0cf          # IRET
     52   nop
     53   int     $0x0a
     54   .byte      0x0cf          # IRET
     55   nop
     56   int     $0x0b
     57   .byte      0x0cf          # IRET
     58   nop
     59   int     $0x0c
     60   .byte      0x0cf          # IRET
     61   nop
     62   int     $0x0d
     63   .byte      0x0cf          # IRET
     64   nop
     65   int     $0x0e
     66   .byte      0x0cf          # IRET
     67   nop
     68   int     $0x0f
     69   .byte      0x0cf          # IRET
     70   nop
     71 
     72 #END
     73