Corrections in DMA code from Mario79

git-svn-id: svn://kolibrios.org@187 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Evgeny Grechnikov (Diamond) 2006-10-20 08:35:15 +00:00
parent 85aa5c3167
commit 7d1826758e
2 changed files with 18 additions and 5 deletions

View File

@ -465,15 +465,15 @@ sayerr:
mov si, 0 ; device index = 0 mov si, 0 ; device index = 0
int 0x1A int 0x1A
jnc .found jnc .found
; b) class 1, subclass 1, programming interface 0x85 ; b) class 1, subclass 1, programming interface 0x8A
mov ax, 0xB103 mov ax, 0xB103
mov ecx, 1*10000h + 1*100h + 0x85 mov ecx, 1*10000h + 1*100h + 0x8A
mov si, 0 ; device index = 0 mov si, 0 ; device index = 0
int 0x1A int 0x1A
jnc .found jnc .found
; c) class 1, subclass 1, programming interface 0x8A ; c) class 1, subclass 1, programming interface 0x85
mov ax, 0xB103 mov ax, 0xB103
mov ecx, 1*10000h + 1*100h + 0x8A mov ecx, 1*10000h + 1*100h + 0x85
mov si, 0 mov si, 0
int 0x1A int 0x1A
jc .nopci jc .nopci

View File

@ -62,10 +62,23 @@ change_task:
pushad pushad
call update_counters call update_counters
; \begin{Mario79}
cmp [dma_task_switched], 1
jne .find_next_task
mov [dma_task_switched], 0
mov ebx, [dma_process]
cmp [0x3000], ebx
je .return
mov edi, [dma_slot_ptr]
mov [0x3000], ebx
mov [0x3010], edi
jmp @f
.find_next_task:
; \end{Mario79}
call find_next_task call find_next_task
test eax, eax ; the same task -> skip switch test eax, eax ; the same task -> skip switch
jnz .return jnz .return
@@:
mov [0xffff],byte 1 mov [0xffff],byte 1
call do_change_task call do_change_task