60,8 → 60,7 |
The returned value NULL means that the initialization has failed. |
Any other value means that configuration was successful; the kernel does not |
try to interpret the value. It can be, for example, pointer to the internal |
data allocated with Kmalloc, or index in some internal table. Remember that |
Kmalloc() is NOT stdcall, it destroys ebx. |
data allocated with Kmalloc, or index in some internal table. |
|
The driver can implement the function |
|
184,9 → 183,7 |
USB_STATUS_OVERRUN = 8 ; too many data from endpoint |
USB_STATUS_UNDERRUN = 9 ; too few data from endpoint |
USB_STATUS_BUFOVERRUN = 12 ; overflow of internal controller buffer |
; possible only for isochronous transfers |
USB_STATUS_BUFUNDERRUN = 13 ; underflow of internal controller buffer |
; possible only for isochronous transfers |
USB_STATUS_CLOSED = 16 ; pipe closed, either explicitly with USBClosePipe |
; or due to device disconnect |
|
196,3 → 193,13 |
implicitly due to device disconnect, all callback functions are called |
with USB_STATUS_CLOSED. The call to DeviceDisconnected() occurs after |
all callbacks. |
|
void* __stdcall USBGetParam(void* pipe0, int param); |
Returns miscellaneous parameters of the device. |
pipe0 is the pointer to the config pipe. |
param = 0: return pointer to device descriptor |
param = 1: return pointer to config descriptor, same as passed to AddDevice |
param = 2: return speed at which the device is operating, one of |
USB_SPEED_FS = 0 ; full-speed |
USB_SPEED_LS = 1 ; low-speed |
USB_SPEED_HS = 2 ; high-speed |