Subversion Repositories Kolibri OS

Rev

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

Rev 4138 Rev 4418
Line 27... Line 27...
27
USB_ENDPOINT_DESCR           = 5
27
USB_ENDPOINT_DESCR           = 5
28
USB_DEVICE_QUALIFIER_DESCR   = 6
28
USB_DEVICE_QUALIFIER_DESCR   = 6
29
USB_OTHER_SPEED_CONFIG_DESCR = 7
29
USB_OTHER_SPEED_CONFIG_DESCR = 7
30
USB_INTERFACE_POWER_DESCR    = 8
30
USB_INTERFACE_POWER_DESCR    = 8
Line 31... Line -...
31
 
-
 
32
; Possible speeds of USB devices
-
 
33
USB_SPEED_FS = 0 ; full-speed
-
 
34
USB_SPEED_LS = 1 ; low-speed
-
 
35
USB_SPEED_HS = 2 ; high-speed
-
 
36
 
31
 
37
; Compile-time setting. If set, the code will dump all descriptors as they are
32
; Compile-time setting. If set, the code will dump all descriptors as they are
38
; read to the debug board.
33
; read to the debug board.
Line 39... Line 34...
39
USB_DUMP_DESCRIPTORS = 1
34
USB_DUMP_DESCRIPTORS = 1
Line 368... Line 363...
368
; the actual address.
363
; the actual address.
369
; Note that the hardware could cache the controller-specific structure,
364
; Note that the hardware could cache the controller-specific structure,
370
; so setting the address could take some time until the cache is evicted.
365
; so setting the address could take some time until the cache is evicted.
371
; Thus, the call is asynchronous; meet us in usb_after_set_address when it will
366
; Thus, the call is asynchronous; meet us in usb_after_set_address when it will
372
; be safe to continue.
367
; be safe to continue.
373
        dbgstr 'address set in device'
368
;        dbgstr 'address set in device'
374
        call    [eax+usb_hardware_func.SetDeviceAddress]
369
        call    [eax+usb_hardware_func.SetDeviceAddress]
375
; 2b. If the port is in non-root hub, clear 'reset in progress' flag.
370
; 2b. If the port is in non-root hub, clear 'reset in progress' flag.
376
; In any case, proceed to 4.
371
; In any case, proceed to 4.
377
        mov     eax, [esi+usb_controller.ResettingHub]
372
        mov     eax, [esi+usb_controller.ResettingHub]
378
        test    eax, eax
373
        test    eax, eax
Line 407... Line 402...
407
 
402
 
408
; This procedure is called from usb_subscription_done when the hardware cache
403
; This procedure is called from usb_subscription_done when the hardware cache
409
; is cleared after request from usb_set_address_callback.
404
; is cleared after request from usb_set_address_callback.
410
; in: ebx -> usb_pipe
405
; in: ebx -> usb_pipe
411
proc usb_after_set_address
406
proc usb_after_set_address
412
        dbgstr 'address set for controller'
407
;        dbgstr 'address set for controller'
413
; Issue control transfer GET_DESCRIPTOR(DEVICE_DESCR) for first 8 bytes.
408
; Issue control transfer GET_DESCRIPTOR(DEVICE_DESCR) for first 8 bytes.
414
; Remember, we still do not know the actual packet size;
409
; Remember, we still do not know the actual packet size;
415
; 8-bytes-request is safe.
410
; 8-bytes-request is safe.
416
; usb_new_device has allocated 8 extra bytes besides sizeof.usb_device_data;
411
; usb_new_device has allocated 8 extra bytes besides sizeof.usb_device_data;