Subversion Repositories Kolibri OS

Rev

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

Rev 4418 Rev 4547
Line 112... Line 112...
112
        add     eax, ecx
112
        add     eax, ecx
113
        pop     ecx
113
        pop     ecx
114
        ret
114
        ret
115
endp
115
endp
Line 116... Line 116...
116
 
116
 
117
; Put the given control pipe in the wait list;
117
; Put the given control/bulk pipe in the wait list;
118
; called when the pipe structure is changed and a possible hardware cache
118
; called when the pipe structure is changed and a possible hardware cache
119
; needs to be synchronized. When it will be known that the cache is updated,
119
; needs to be synchronized. When it will be known that the cache is updated,
120
; usb_subscription_done procedure will be called.
120
; usb_subscription_done procedure will be called.
121
proc usb_subscribe_control
121
proc usb_subscribe_control
Line 126... Line 126...
126
        mov     [esi+usb_controller.WaitPipeListAsync], ebx
126
        mov     [esi+usb_controller.WaitPipeListAsync], ebx
127
@@:
127
@@:
128
        ret
128
        ret
129
endp
129
endp
Line -... Line 130...
-
 
130
 
-
 
131
; Same as usb_subscribe_control, but for interrupt/isochronous pipe.
-
 
132
proc usb_subscribe_periodic
-
 
133
        cmp     [ebx+usb_pipe.NextWait], -1
-
 
134
        jnz     @f
-
 
135
        mov     eax, [esi+usb_controller.WaitPipeListPeriodic]
-
 
136
        mov     [ebx+usb_pipe.NextWait], eax
-
 
137
        mov     [esi+usb_controller.WaitPipeListPeriodic], ebx
-
 
138
@@:
-
 
139
        ret
-
 
140
endp
130
 
141
 
131
; Called after synchronization of hardware cache with software changes.
142
; Called after synchronization of hardware cache with software changes.
132
; Continues process of device enumeration based on when it was delayed
143
; Continues process of device enumeration based on when it was delayed
133
; due to call to usb_subscribe_control.
144
; due to call to usb_subscribe_control.
134
proc usb_subscription_done
145
proc usb_subscription_done
Line 252... Line 263...
252
        mov     eax, [esi+usb_controller.WaitPipeListAsync+edx]
263
        mov     eax, [esi+usb_controller.WaitPipeListAsync+edx]
253
        mov     [ebx+usb_pipe.NextWait], eax
264
        mov     [ebx+usb_pipe.NextWait], eax
254
        mov     [esi+usb_controller.WaitPipeListAsync+edx], ebx
265
        mov     [esi+usb_controller.WaitPipeListAsync+edx], ebx
255
        jmp     .continue
266
        jmp     .continue
256
.process:
267
.process:
257
; 7. Call the handler depending on USB_FLAG_CLOSED.
268
; 7. Call the handler depending on USB_FLAG_CLOSED and USB_FLAG_DISABLED.
258
        or      [ebx+usb_pipe.NextWait], -1
269
        or      [ebx+usb_pipe.NextWait], -1
259
        test    [ebx+usb_pipe.Flags], USB_FLAG_CLOSED
270
        test    [ebx+usb_pipe.Flags], USB_FLAG_CLOSED
260
        jz      .nodisconnect
271
        jz      .nodisconnect
261
        call    usb_pipe_closed
272
        call    usb_pipe_closed
262
        jmp     .continue
273
        jmp     .continue
263
.nodisconnect:
274
.nodisconnect:
-
 
275
        test    [ebx+usb_pipe.Flags], USB_FLAG_DISABLED
-
 
276
        jz      .nodisabled
-
 
277
        call    usb_pipe_disabled
-
 
278
        jmp     .continue
-
 
279
.nodisabled:
264
        call    usb_subscription_done
280
        call    usb_subscription_done
265
.continue:
281
.continue:
266
; 8. Restore edx and next pipe saved in step 5 and continue the loop.
282
; 8. Restore edx and next pipe saved in step 5 and continue the loop.
267
        pop     ebx
283
        pop     ebx
268
        pop     edx
284
        pop     edx