Ignore:
Timestamp:
2006-10-27T13:34:20Z (18 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
ec04b20
Parents:
16d71f41
Message:

amd64: adopt new IRQ interface

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/amd64/include/interrupt.h

    r16d71f41 r8607db8  
    4646
    4747#define IVT_EXCBASE             0
    48 #define IVT_IRQBASE             (IVT_EXCBASE+EXC_COUNT)
    49 #define IVT_FREEBASE            (IVT_IRQBASE+IRQ_COUNT)
     48#define IVT_IRQBASE             (IVT_EXCBASE + EXC_COUNT)
     49#define IVT_FREEBASE    (IVT_IRQBASE + IRQ_COUNT)
    5050
    51 #define IRQ_CLK         0
    52 #define IRQ_KBD         1
    53 #define IRQ_PIC1        2
     51#define IRQ_CLK                 0
     52#define IRQ_KBD                 1
     53#define IRQ_PIC1                2
    5454#define IRQ_PIC_SPUR    7
     55#define IRQ_MOUSE               12
    5556
    5657/* this one must have four least significant bits set to ones */
    57 #define VECTOR_APIC_SPUR        (IVT_ITEMS-1)
     58#define VECTOR_APIC_SPUR        (IVT_ITEMS - 1)
    5859
    59 #if (((VECTOR_APIC_SPUR + 1)%16) || VECTOR_APIC_SPUR >= IVT_ITEMS)
     60#if (((VECTOR_APIC_SPUR + 1) % 16) || VECTOR_APIC_SPUR >= IVT_ITEMS)
    6061#error Wrong definition of VECTOR_APIC_SPUR
    6162#endif
    6263
    63 #define VECTOR_DEBUG            1
    64 #define VECTOR_PIC_SPUR         (IVT_IRQBASE+IRQ_PIC_SPUR)
    65 #define VECTOR_CLK              (IVT_IRQBASE+IRQ_CLK)
    66 #define VECTOR_KBD              (IVT_IRQBASE+IRQ_KBD)
    67 
    68 #define VECTOR_TLB_SHOOTDOWN_IPI        (IVT_FREEBASE+0)
    69 #define VECTOR_WAKEUP_IPI               (IVT_FREEBASE+1)
    70 #define VECTOR_DEBUG_IPI                (IVT_FREEBASE+2)
     64#define VECTOR_DEBUG                            1
     65#define VECTOR_CLK                                      (IVT_IRQBASE + IRQ_CLK)
     66#define VECTOR_PIC_SPUR                         (IVT_IRQBASE + IRQ_PIC_SPUR)
     67#define VECTOR_SYSCALL                          IVT_FREEBASE
     68#define VECTOR_TLB_SHOOTDOWN_IPI        (IVT_FREEBASE + 1)
     69#define VECTOR_DEBUG_IPI                        (IVT_FREEBASE + 2)
    7170
    7271/** This is passed to interrupt handlers */
     
    113112extern void (* eoi_function)(void);
    114113
    115 extern void print_info_errcode(int n, istate_t *istate);
    116 extern void null_interrupt(int n, istate_t *istate);
    117 extern void gp_fault(int n, istate_t *istate);
    118 extern void nm_fault(int n, istate_t *istate);
    119 extern void ss_fault(int n, istate_t *istate);
    120 extern void page_fault(int n, istate_t *istate);
    121 extern void syscall(int n, istate_t *istate);
    122 extern void tlb_shootdown_ipi(int n, istate_t *istate);
    123 
     114extern void decode_istate(int n, istate_t *istate);
     115extern void interrupt_init(void);
    124116extern void trap_virtual_enable_irqs(uint16_t irqmask);
    125117extern void trap_virtual_disable_irqs(uint16_t irqmask);
    126 extern void trap_virtual_eoi(void);
    127118/* AMD64 - specific page handler */
    128119extern void ident_page_fault(int n, istate_t *istate);
Note: See TracChangeset for help on using the changeset viewer.