load/eject CD tray functions check that input device is CD/DVD
git-svn-id: svn://kolibrios.org@590 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
1d9fff9e92
commit
3e7d2e5267
@ -4991,13 +4991,25 @@ syscall_cdaudio: ; CD
|
||||
and eax, 1
|
||||
mov [DiskNumber], eax
|
||||
call reserve_cd_channel
|
||||
and ebx, 3
|
||||
inc ebx
|
||||
mov [cdpos], ebx
|
||||
add ebx, ebx
|
||||
mov cl, 8
|
||||
sub cl, bl
|
||||
mov al, [DRIVE_DATA+1]
|
||||
shr al, cl
|
||||
test al, 2
|
||||
jz .err
|
||||
ret
|
||||
.free:
|
||||
call free_cd_channel
|
||||
and [cd_status], 0
|
||||
ret
|
||||
.err:
|
||||
call .free
|
||||
pop eax
|
||||
ret
|
||||
|
||||
align 4
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user