Enable display first to catch ps2 output

This commit is contained in:
Jeremy Soller 2016-09-01 20:52:52 -06:00
parent aad69e8a6c
commit 3d79c653bd
2 changed files with 6 additions and 39 deletions

View file

@ -6,8 +6,8 @@ pub mod serial;
pub unsafe fn init(active_table: &mut ActivePageTable){
serial::init();
ps2::init();
display::init(active_table);
ps2::init();
}
pub unsafe fn init_ap(active_table: &mut ActivePageTable) {

View file

@ -7,12 +7,9 @@ vesa:
mov di, VBECardInfo
int 0x10
cmp ax, 0x4F
je .edid
je .findmode
mov eax, 1
ret
.edid:
cmp dword [.required], 0 ;if both required x and required y are set, forget this
jne near .findmode
.resetlist:
;if needed, reset mins/maxes/stuff
xor cx, cx
@ -78,9 +75,9 @@ vesa:
mov cx, [.currentmode]
mov [.goodmode], cx
push esi
call decshowrm
mov al, ':'
call charrm
; call decshowrm
; mov al, ':'
; call charrm
mov cx, [VBEModeInfo.xresolution]
call decshowrm
mov al, 'x'
@ -122,8 +119,6 @@ vesa:
.requiredy dw 0 ;768
.requiredmode dw 0
.noedidmsg db "EDID not supported.",10,13,0
.edidmsg db " is supported.",10,13,0
.modeok db ": Is this OK?(y/n)",10,13,0
.goodmode dw 0
@ -209,31 +204,3 @@ charrm: ;char must be in al
mov ah, 0xE
int 10h
ret
; .bestmode: ;preference is width > height > color
; mov bx, [VBEModeInfo.xresolution]
; cmp bx, [.width]
; ja .switchmode
; jb .searchmodes
; mov bx, [VBEModeInfo.yresolution]
; cmp bx, [.height]
; ja .switchmode
; jb .searchmodes
; mov bl, [VBEModeInfo.bitsperpixel]
; cmp bl, [.color]
; jb .searchmodes
; .switchmode:
; mov cx, [.currentmode]
; mov [.mode], cx
; mov bx, [VBEModeInfo.xresolution]
; mov [.width], bx
; mov bx, [VBEModeInfo.yresolution]
; mov [.height], bx
; mov bl, [VBEModeInfo.bitsperpixel]
; mov [.color], bl
; jmp .searchmodes
; .mode dw 0
; .color db 0
; .height dw 0
; .width dw 0