additional support for rhd driver

git-svn-id: svn://kolibrios.org@747 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Sergey Semyonov (Serge) 2008-02-18 21:38:13 +00:00
parent 89d030e950
commit e97775cadc
4 changed files with 19 additions and 3 deletions

View File

@ -197,6 +197,7 @@ endp
align 4 align 4
proc pci_read16 stdcall, bus:dword, devfn:dword, reg:dword proc pci_read16 stdcall, bus:dword, devfn:dword, reg:dword
push ebx
xor eax, eax xor eax, eax
xor ebx, ebx xor ebx, ebx
mov ah, byte [bus] mov ah, byte [bus]
@ -204,11 +205,13 @@ proc pci_read16 stdcall, bus:dword, devfn:dword, reg:dword
mov bh, byte [devfn] mov bh, byte [devfn]
mov bl, byte [reg] mov bl, byte [reg]
call pci_read_reg call pci_read_reg
pop ebx
ret ret
endp endp
align 4 align 4
proc pci_read8 stdcall, bus:dword, devfn:dword, reg:dword proc pci_read8 stdcall, bus:dword, devfn:dword, reg:dword
push ebx
xor eax, eax xor eax, eax
xor ebx, ebx xor ebx, ebx
mov ah, byte [bus] mov ah, byte [bus]
@ -216,11 +219,13 @@ proc pci_read8 stdcall, bus:dword, devfn:dword, reg:dword
mov bh, byte [devfn] mov bh, byte [devfn]
mov bl, byte [reg] mov bl, byte [reg]
call pci_read_reg call pci_read_reg
pop ebx
ret ret
endp endp
align 4 align 4
proc pci_write8 stdcall, bus:dword, devfn:dword, reg:dword, val:dword proc pci_write8 stdcall, bus:dword, devfn:dword, reg:dword, val:dword
push ebx
xor eax, eax xor eax, eax
xor ebx, ebx xor ebx, ebx
mov ah, byte [bus] mov ah, byte [bus]
@ -229,11 +234,13 @@ proc pci_write8 stdcall, bus:dword, devfn:dword, reg:dword, val:dword
mov bl, byte [reg] mov bl, byte [reg]
mov ecx, [val] mov ecx, [val]
call pci_write_reg call pci_write_reg
pop ebx
ret ret
endp endp
align 4 align 4
proc pci_write16 stdcall, bus:dword, devfn:dword, reg:dword, val:dword proc pci_write16 stdcall, bus:dword, devfn:dword, reg:dword, val:dword
push ebx
xor eax, eax xor eax, eax
xor ebx, ebx xor ebx, ebx
mov ah, byte [bus] mov ah, byte [bus]
@ -242,6 +249,7 @@ proc pci_write16 stdcall, bus:dword, devfn:dword, reg:dword, val:dword
mov bl, byte [reg] mov bl, byte [reg]
mov ecx, [val] mov ecx, [val]
call pci_write_reg call pci_write_reg
pop ebx
ret ret
endp endp

View File

@ -983,7 +983,7 @@ malloc_large:
align 4 align 4
init_malloc: init_malloc:
stdcall kernel_alloc, 0x20000 stdcall kernel_alloc, 0x30000
mov [mst.top], eax mov [mst.top], eax
mov [mst.topsize], 128*1024 mov [mst.topsize], 128*1024

View File

@ -1057,8 +1057,8 @@ new_services:
mov [esp+36], eax mov [esp+36], eax
ret ret
@@: @@:
cmp eax, 21 cmp eax, 21 ;for test purposes only
ja @f ja @f ;will be removed soon
cmp ebx, OS_BASE cmp ebx, OS_BASE
jae .fail jae .fail

View File

@ -275,10 +275,18 @@ __exports:
free_kernel_space, 'FreeKernelSpace', \ ; stdcall free_kernel_space, 'FreeKernelSpace', \ ; stdcall
kernel_alloc, 'KernelAlloc', \ ; stdcall kernel_alloc, 'KernelAlloc', \ ; stdcall
kernel_free, 'KernelFree', \ ; stdcall kernel_free, 'KernelFree', \ ; stdcall
malloc, 'Kmalloc', \
free, 'Kfree', \
map_io_mem, 'MapIoMem', \ ; stdcall map_io_mem, 'MapIoMem', \ ; stdcall
\
pci_api, 'PciApi', \ pci_api, 'PciApi', \
pci_read8, 'PciRead8', \ ; stdcall
pci_read16, 'PciRead16', \ ; stdcall
pci_read32, 'PciRead32', \ ; stdcall pci_read32, 'PciRead32', \ ; stdcall
pci_write8, 'PciWrite8', \ ; stdcall
pci_write16, 'PciWrite16', \ ; stdcall
pci_write32, 'PciWrite32', \ ; stdcall pci_write32, 'PciWrite32', \ ; stdcall
\
reg_service, 'RegService', \ reg_service, 'RegService', \
user_alloc, 'UserAlloc', \ ; stdcall user_alloc, 'UserAlloc', \ ; stdcall
user_free, 'UserFree', \ ; stdcall user_free, 'UserFree', \ ; stdcall