Subversion Repositories Kolibri OS

Rev

Rev 3185 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3185 Rev 3346
Line 12... Line 12...
12
;;          GNU GENERAL PUBLIC LICENSE                             ;;
12
;;          GNU GENERAL PUBLIC LICENSE                             ;;
13
;;             Version 2, June 1991                                ;;
13
;;             Version 2, June 1991                                ;;
14
;;                                                                 ;;
14
;;                                                                 ;;
15
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
15
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Line 16... Line 16...
16
 
16
 
Line 17... Line 17...
17
$Revision: 3185 $
17
$Revision: 3346 $
Line 18... Line 18...
18
 
18
 
Line 26... Line 26...
26
 
26
 
Line 27... Line 27...
27
ends
27
ends
Line 28... Line -...
28
 
-
 
29
struct  ETH_DEVICE      NET_DEVICE
-
 
30
 
-
 
31
        set_mode        dd ?
-
 
32
        get_mode        dd ?
-
 
33
 
-
 
34
        set_MAC         dd ?
-
 
35
        get_MAC         dd ?
28
 
Line 36... Line 29...
36
 
29
struct  ETH_DEVICE      NET_DEVICE
Line 37... Line 30...
37
        mode            dd ?
30
 
Line 197... Line 190...
197
        dd      .packets_tx     ; 0
190
        dd      .packets_tx     ; 0
198
        dd      .packets_rx     ; 1
191
        dd      .packets_rx     ; 1
199
        dd      .bytes_tx       ; 2
192
        dd      .bytes_tx       ; 2
200
        dd      .bytes_rx       ; 3
193
        dd      .bytes_rx       ; 3
201
        dd      .read_mac       ; 4
194
        dd      .read_mac       ; 4
202
        dd      .write_mac      ; 5
195
        dd      .state          ; 5
203
  .number = ($ - .table) / 4 - 1
196
  .number = ($ - .table) / 4 - 1
Line 204... Line 197...
204
 
197
 
205
  .error:
198
  .error:
206
        or      eax, -1
199
        or      eax, -1
Line 232... Line 225...
232
        movzx   ebx, word [eax + ETH_DEVICE.mac]
225
        movzx   ebx, word [eax + ETH_DEVICE.mac]
233
        mov     eax, dword [eax + ETH_DEVICE.mac + 2]
226
        mov     eax, dword [eax + ETH_DEVICE.mac + 2]
234
        mov     [esp+20+4], ebx                         ; TODO: fix this ugly code
227
        mov     [esp+20+4], ebx                         ; TODO: fix this ugly code
235
        ret
228
        ret
Line 236... Line 229...
236
 
229
 
237
  .write_mac:
-
 
238
        push    ecx
-
 
239
        push    dx
230
  .state:
240
        call    [eax + ETH_DEVICE.set_MAC]
231
        mov     eax, [eax + NET_DEVICE.state]