Subversion Repositories Kolibri OS

Rev

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

Rev 5442 Rev 5522
Line 13... Line 13...
13
;;         GNU GENERAL PUBLIC LICENSE                              ;;
13
;;         GNU GENERAL PUBLIC LICENSE                              ;;
14
;;          Version 2, June 1991                                   ;;
14
;;          Version 2, June 1991                                   ;;
15
;;                                                                 ;;
15
;;                                                                 ;;
16
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
16
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Line 17... Line 17...
17
 
17
 
Line 18... Line 18...
18
$Revision: 5442 $
18
$Revision: 5522 $
Line 19... Line 19...
19
 
19
 
20
struct  SOCKET
20
struct  SOCKET
Line 177... Line 177...
177
ends
177
ends
Line 178... Line 178...
178
 
178
 
Line 179... Line 179...
179
struct  socket_queue_entry
179
struct  socket_queue_entry
180
 
-
 
181
        data_ptr                dd ?
180
 
-
 
181
        data_ptr                dd ?
Line 182... Line 182...
182
        buf_ptr                 dd ?
182
        data_size               dd ?
Line 183... Line 183...
183
        data_size               dd ?
183
        buf_ptr                 dd ?
Line 820... Line 820...
820
        test    ecx, ecx
820
        test    ecx, ecx
821
        jz      .nd
821
        jz      .nd
822
        rep movsd
822
        rep movsd
823
  .nd:
823
  .nd:
Line 824... Line 824...
824
 
824
 
825
        call    NET_packet_free
825
        call    NET_BUFF_free
826
        pop     ecx eax                                         ; return number of bytes copied to application
826
        pop     ecx eax                                         ; return number of bytes copied to application
827
        xor     ebx, ebx
827
        xor     ebx, ebx
Line 828... Line 828...
828
        ret
828
        ret
Line 1439... Line 1439...
1439
;
1439
;
1440
;  IN:  eax = socket ptr
1440
;  IN:  eax = socket ptr
1441
;       ecx = data size
1441
;       ecx = data size
1442
;       esi = ptr to data
1442
;       esi = ptr to data
1443
;       [esp] = ptr to buf
1443
;       [esp] = ptr to buf
1444
;       [esp + 4] = buf size
-
 
1445
;
1444
;
1446
;  OUT: /
1445
;  OUT: /
1447
;
1446
;
1448
;-----------------------------------------------------------------
1447
;-----------------------------------------------------------------
1449
align 4
1448
align 4
1450
SOCKET_input:
1449
SOCKET_input:
Line 1451... Line 1450...
1451
 
1450
 
Line 1452... Line 1451...
1452
        DEBUGF  DEBUG_NETWORK_VERBOSE, "SOCKET_input: socket=%x, data=%x size=%u\n", eax, esi, ecx
1451
        DEBUGF  DEBUG_NETWORK_VERBOSE, "SOCKET_input: socket=%x, data=%x size=%u\n", eax, esi, ecx
1453
 
1452
 
1454
        mov     [esp+4], ecx
1453
        push    ecx
Line 1455... Line 1454...
1455
        push    esi
1454
        push    esi
Line 1473... Line 1472...
1473
        pusha
1472
        pusha
1474
        lea     ecx, [eax + SOCKET.mutex]
1473
        lea     ecx, [eax + SOCKET.mutex]
1475
        call    mutex_unlock
1474
        call    mutex_unlock
1476
        popa
1475
        popa
Line 1477... Line 1476...
1477
 
1476
 
1478
        call    NET_packet_free
-
 
1479
        add     esp, 8
-
 
1480
 
1477
        call    NET_BUFF_free
Line 1481... Line 1478...
1481
        ret
1478
        ret
1482
 
1479
 
1483
 
1480
 
1484
;--------------------------
-
 
1485
;
1481
;--------------------------
1486
; IN: eax = ptr to ring struct (just a buffer of the right size)
1482
;
1487
; OUT: eax = unchanged / 0 on error
1483
; eax = ptr to ring struct (just a buffer of the right size)
Line 1488... Line 1484...
1488
;
1484
;