Subversion Repositories Kolibri OS

Rev

Rev 2288 | Rev 2455 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 2288 Rev 2443
Line 59... Line 59...
59
        mov     [acpi_dev_size], ebx
59
        mov     [acpi_dev_size], ebx
Line 60... Line 60...
60
 
60
 
Line 61... Line 61...
61
        call    IRQ_mask_all
61
        call    IRQ_mask_all
62
 
62
 
63
; IOAPIC init
63
; IOAPIC init
Line 64... Line 64...
64
        stdcall map_io_mem, [acpi_ioapic_base], 0x20, PG_SW
64
        stdcall map_io_mem, [acpi_ioapic_base], 0x20, PG_SW+PG_NOCACHE
65
        mov     [IOAPIC_base], eax
65
        mov     [IOAPIC_base], eax
66
 
66
 
Line 119... Line 119...
119
        ret
119
        ret
Line 120... Line 120...
120
 
120
 
121
;===========================================================
121
;===========================================================
122
align 4
122
align 4
123
LAPIC_init:
-
 
124
        ; Check MSR support
-
 
125
        ;....
-
 
126
        ; Get LAPIC base address
-
 
127
; mov ecx, 0x1b
-
 
128
; rdmsr       ; it may be replaced to
-
 
Line -... Line 123...
-
 
123
LAPIC_init:
-
 
124
 
-
 
125
        cmp     [LAPIC_BASE], 0
129
; and ax, 0xf000    ; mov eax, 0xfee00000
126
        jne     .done
130
 
127
 
131
        stdcall map_io_mem, [acpi_lapic_base], 0x1000, PG_SW
128
        stdcall map_io_mem, [acpi_lapic_base], 0x1000, PG_SW+PG_NOCACHE
Line 132... Line 129...
132
        mov     [LAPIC_BASE], eax
129
        mov     [LAPIC_BASE], eax
133
        mov     esi, eax
130
        mov     esi, eax
Line 198... Line 195...
198
        shr     eax, 6      ; eax /= 64; APIC ticks per 0.01 sec
195
        shr     eax, 6      ; eax /= 64; APIC ticks per 0.01 sec
Line 199... Line 196...
199
 
196
 
200
        ; Start (every 0.01 sec)
197
        ; Start (every 0.01 sec)
201
        mov     dword[esi + APIC_LVT_timer], 0x30020; periodic int 0x20
198
        mov     dword[esi + APIC_LVT_timer], 0x30020; periodic int 0x20
-
 
199
        mov     dword[esi + APIC_timer_init], eax
-
 
200
 
202
        mov     dword[esi + APIC_timer_init], eax
201
.done:
Line 203... Line 202...
203
        ret
202
        ret
204
 
203
 
205
;===========================================================
204
;===========================================================