Correcting code style
This commit is contained in:
parent
f4daef6374
commit
1d9d02196c
|
@ -149,28 +149,28 @@ ata_read:
|
||||||
push rdx
|
push rdx
|
||||||
push rcx
|
push rcx
|
||||||
push rdi
|
push rdi
|
||||||
mov dx,1f6h ;Drive and head port
|
mov dx, 0x1f6 ;Drive and head port
|
||||||
mov al,0a0h ;Drive 0, head 0
|
mov al, 0x0a0 ;Drive 0, head 0
|
||||||
out dx,al
|
out dx,al
|
||||||
|
|
||||||
mov dx,1f2h ;Sector count port
|
mov dx, 0x1f2 ;Sector count port
|
||||||
mov al, 1 ;Read one sector
|
mov al, 1 ;Read one sector
|
||||||
out dx, al
|
out dx, al
|
||||||
|
|
||||||
mov dx,1f3h ;Sector number port
|
mov dx, 0x1f3 ;Sector number port
|
||||||
mov al, 1 ;Read sector one
|
mov al, 1 ;Read sector one
|
||||||
out dx, al
|
out dx, al
|
||||||
|
|
||||||
mov dx,1f4h ;Cylinder low port
|
mov dx, 0x1f4 ;Cylinder low port
|
||||||
mov al, 0 ;Cylinder 0
|
mov al, 0 ;Cylinder 0
|
||||||
out dx, al
|
out dx, al
|
||||||
|
|
||||||
mov dx,1f5h ;Cylinder high port
|
mov dx, 0x1f5 ;Cylinder high port
|
||||||
mov al, 0 ;The rest of the cylinder 0
|
mov al, 0 ;The rest of the cylinder 0
|
||||||
out dx, al
|
out dx, al
|
||||||
|
|
||||||
mov dx,1f7h ;Command port
|
mov dx, 0x1f7 ;Command port
|
||||||
mov al,20h ;Read with retry.
|
mov al, 20 ;Read with retry.
|
||||||
out dx, al
|
out dx, al
|
||||||
still_going:
|
still_going:
|
||||||
in al, dx
|
in al, dx
|
||||||
|
@ -181,7 +181,7 @@ still_going:
|
||||||
|
|
||||||
mov cx, 512/2 ;One sector /2
|
mov cx, 512/2 ;One sector /2
|
||||||
mov rdi, buffer
|
mov rdi, buffer
|
||||||
mov dx,1f0h ;Data port - data comes in and out of here.
|
mov dx, 0x1f0 ;Data port - data comes in and out of here.
|
||||||
rep insw
|
rep insw
|
||||||
pop rdi
|
pop rdi
|
||||||
pop rcx
|
pop rcx
|
||||||
|
@ -195,5 +195,6 @@ still_going:
|
||||||
mov esi, end
|
mov esi, end
|
||||||
call write
|
call write
|
||||||
ret
|
ret
|
||||||
|
|
||||||
buffer: times 512 db "_"
|
buffer: times 512 db "_"
|
||||||
end: db "[End of Sector]", 0x0
|
end: db "[End of Sector]", 0x0
|
||||||
|
|
Loading…
Reference in New Issue