Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 769 → Rev 768

/kernel/trunk/core/sys32.inc
183,12 → 183,20
{
forward
p_irq#num :
save_ring3_context
mov edi, num
jmp irqhandler
jmp irq_c
}
 
irqh 2,3,4,5,7,8,9,10,11
irqh 2,5,7,8,9,10,11
 
irq_c:
mov ax, app_data ;os_data
mov ds, ax
mov es, ax
call irqhandler
restore_ring3_context
iret
 
p_irq6:
save_ring3_context
200,7 → 208,42
restore_ring3_context
iret
 
p_irq3:
save_ring3_context
mov ax, app_data ;os_data
mov ds, ax
mov es, ax
cmp [com2_mouse_detected],0
je old_irq3_handler
mov esi, com2_mouse
mov dx, 2F8h ;[COMPortBaseAddr]
call check_mouse_data_com
jmp p_irq3_1
old_irq3_handler:
mov edi,3
call irqhandler
p_irq3_1:
restore_ring3_context
iret
 
p_irq4:
save_ring3_context
mov ax, app_data ;os_data
mov ds, ax
mov es, ax
cmp [com1_mouse_detected],0
je old_irq4_handler
mov esi, com1_mouse
mov dx, 3F8h ;[COMPortBaseAddr]
call check_mouse_data_com
jmp p_irq4_1
old_irq4_handler:
mov edi,4
call irqhandler
p_irq4_1:
restore_ring3_context
iret
 
p_irq14:
save_ring3_context
mov ax, app_data ;os_data
260,6 → 303,7
cmp [v86_irqhooks+edi*8], 0
jnz v86_irq2
 
push edi
 
mov esi,edi ; 1
shl esi,6 ; 1
268,6 → 312,8
add edi,IRQ_SAVE
mov ecx,16
 
mov [check_idle_semaphore],5
 
irqnewread:
dec ecx
js irqover
322,6 → 368,15
irqfull:
irqover:
 
mov al,0x20 ; ready for next irq
out 0x20,al
 
pop ebx
cmp ebx,7
jbe noa0
out 0xa0,al
noa0:
 
ret
 
 
/kernel/trunk/core/dll.inc
24,16 → 24,7
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:
68,69 → 59,83
irq_serv:
 
.irq_1:
push 1
push eax
mov eax, 1
jmp .main
align 4
.irq_2:
push 2
push eax
mov eax, 2
jmp .main
align 4
.irq_3:
push 3
push eax
mov eax, 3
jmp .main
align 4
.irq_4:
push 4
push eax
mov eax, 4
jmp .main
align 4
.irq_5:
push 5
push eax
mov eax, 5
jmp .main
align 4
.irq_6:
push 6
push eax
mov eax, 6
jmp .main
align 4
.irq_7:
push 7
push eax
mov eax, 7
jmp .main
align 4
.irq_8:
push 8
push eax
mov eax, 8
jmp .main
align 4
.irq_9:
push 9
push eax
mov eax, 9
jmp .main
align 4
.irq_10:
push 10
push eax
mov eax, 10
jmp .main
align 4
.irq_11:
push 11
push eax
mov eax, 11
jmp .main
align 4
.irq_12:
push 12
push eax
mov eax, 12
jmp .main
align 4
.irq_13:
push 13
push eax
mov eax, 13
jmp .main
align 4
.irq_14:
push 14
push eax
mov eax, 14
jmp .main
align 4
.irq_15:
push 15
push eax
mov eax, 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
146,8 → 151,9
mov [check_idle_semaphore],5
 
.exit:
restore_ring3_context
 
cmp dword [esp + 32], 8
cmp eax, 8
mov al, 0x20
jb @f
out 0xa0, al
154,9 → 160,7
@@:
out 0x20, al
 
restore_ring3_context
add esp, 4
 
pop eax
iret
 
align 4
/kernel/trunk/core/exports.inc
18,8 → 18,6
szAttachIntHandler db 'AttachIntHandler',0
szFpuSave db 'FpuSave',0
szFpuRestore db 'FpuRestore',0
szReservePortArea db 'ReservePortArea',0
szBoot_Log db 'Boot_Log',0
 
szPciApi db 'PciApi', 0
szPciRead32 db 'PciRead32', 0
90,8 → 88,6
dd szAttachIntHandler, attach_int_handler
dd szFpuSave , fpu_save
dd szFpuRestore , fpu_restore
dd szReservePortArea , r_f_port_area
dd szBoot_Log , boot_log
 
dd szPciApi , pci_api
dd szPciRead32 , pci_read32