24,7 → 24,16 |
mov eax, [handler] |
test eax, eax |
jz .err |
cmp [irq_owner + 4 * ebx], 0 |
jne .err |
mov [irq_tab+ebx*4], eax |
|
;push eax |
;mov eax, [TASK_BASE] |
;mov eax, [eax + TASKDATA.pid] |
mov [irq_owner + 4 * ebx], 1 |
;pop eax |
|
stdcall enable_irq, [irq] |
ret |
.err: |
59,83 → 68,69 |
irq_serv: |
|
.irq_1: |
push eax |
mov eax, 1 |
push 1 |
jmp .main |
align 4 |
.irq_2: |
push eax |
mov eax, 2 |
push 2 |
jmp .main |
align 4 |
.irq_3: |
push eax |
mov eax, 3 |
push 3 |
jmp .main |
align 4 |
.irq_4: |
push eax |
mov eax, 4 |
push 4 |
jmp .main |
align 4 |
.irq_5: |
push eax |
mov eax, 5 |
push 5 |
jmp .main |
align 4 |
.irq_6: |
push eax |
mov eax, 6 |
push 6 |
jmp .main |
align 4 |
.irq_7: |
push eax |
mov eax, 7 |
push 7 |
jmp .main |
align 4 |
.irq_8: |
push eax |
mov eax, 8 |
push 8 |
jmp .main |
align 4 |
.irq_9: |
push eax |
mov eax, 9 |
push 9 |
jmp .main |
align 4 |
.irq_10: |
push eax |
mov eax, 10 |
push 10 |
jmp .main |
align 4 |
.irq_11: |
push eax |
mov eax, 11 |
push 11 |
jmp .main |
align 4 |
.irq_12: |
push eax |
mov eax, 12 |
push 12 |
jmp .main |
align 4 |
.irq_13: |
push eax |
mov eax, 13 |
push 13 |
jmp .main |
align 4 |
.irq_14: |
push eax |
mov eax, 14 |
push 14 |
jmp .main |
align 4 |
.irq_15: |
push eax |
mov eax, 15 |
push 15 |
jmp .main |
|
align 16 |
.main: |
save_ring3_context |
mov eax, [esp + 32] |
mov bx, app_data ;os_data |
mov ds, bx |
mov es, bx |
151,9 → 146,8 |
mov [check_idle_semaphore],5 |
|
.exit: |
restore_ring3_context |
|
cmp eax, 8 |
cmp dword [esp + 32], 8 |
mov al, 0x20 |
jb @f |
out 0xa0, al |
160,7 → 154,9 |
@@: |
out 0x20, al |
|
pop eax |
restore_ring3_context |
add esp, 4 |
|
iret |
|
align 4 |