Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 781 → Rev 782

/kernel/trunk/network/eth_drv/drivers/i8255x.inc
307,23 → 307,8
ret
 
 
 
;***************************************************************************
; Function
; I8255x_reset
; Description
; Place the chip (ie, the ethernet card) into a virgin state
; No inputs
; All registers destroyed
;
;***************************************************************************
I8255x_reset:
ret
 
 
 
;***************************************************************************
; Function
; I8255x_probe
; Description
; Searches for an ethernet card, enables it and clears the rx buffer
331,6 → 316,7
;
;***************************************************************************
I8255x_probe:
DEBUGF 1," K : Probing i8255x device \n"
mov eax, [io_addr]
 
mov ebx, [pci_bus]
431,9 → 417,11
mov [rxfd_command], ax
 
mov eax, rxfd_status
sub eax, OS_BASE
mov [rxfd_link], eax
 
mov eax, Ether_buffer
sub eax, OS_BASE
mov [rxfd_rx_buf_addr], eax
 
mov ax, 0
446,6 → 434,7
add edx, 4 ; SCBPointer
 
mov eax, rxfd_status
sub eax, OS_BASE
out dx, eax
 
mov edx, [io_addr]
468,6 → 457,7
add edx, 4 ; SCBPointer
 
mov eax, rxfd_status
sub eax, OS_BASE
out dx, eax
 
mov edx, [io_addr]
499,6 → 489,7
mov ax, 2
mov [confcmd_command], ax
mov eax, txfd
sub eax, OS_BASE
mov [confcmd_link], eax
 
mov ax, 1
508,8 → 499,11
mov [txfd_status], ax
 
mov eax, confcmd
sub eax, OS_BASE
mov [txfd_link], eax
 
 
 
; ETH_ALEN is 6 bytes
 
mov esi, eeprom_data
543,6 → 537,7
add esi, 4
loop drp001
 
 
mov esi, eeprom_data + (6 * 4)
mov eax, [esi]
shr eax, 8
587,6 → 582,7
mov [ebx + 21], al
 
mov eax, txfd
sub eax, OS_BASE
mov edx, [io_addr]
add edx, 4 ; SCBPointer
out dx, eax
617,6 → 613,20
 
;***************************************************************************
; Function
; I8255x_reset
; Description
; Place the chip (ie, the ethernet card) into a virgin state
; No inputs
; All registers destroyed
;
;***************************************************************************
I8255x_reset:
ret
 
 
 
;***************************************************************************
; Function
; I8255x_poll
;
; Description
642,6 → 652,7
add edx, 4 ; SCBPointer
 
mov eax, rxfd_status
sub eax, OS_BASE
out dx, eax
 
mov edx, [io_addr]
707,8 → 718,10
mov eax, 0x02208000
mov [txfd_count], eax
mov eax, txfd_tx_buf_addr0
sub eax, OS_BASE
mov [txfd_tx_desc_addr], eax
mov eax, hdr
sub eax, OS_BASE
mov [txfd_tx_buf_addr0], eax
mov eax, 14 ; sizeof hdr
mov [txfd_tx_buf_size0], eax
715,11 → 728,13
 
; Copy the buffer address and size in
mov eax, esi
sub eax, OS_BASE
mov [txfd_tx_buf_addr1], eax
mov eax, ecx
mov [txfd_tx_buf_size1], eax
 
mov eax, txfd
sub eax, OS_BASE
mov edx, [io_addr]
add edx, 4 ; SCBPointer
out dx, eax