Changeset f9a0cef in mainline
- Timestamp:
- 2010-12-13T00:31:22Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 37f7cfe, ea5dbaf
- Parents:
- 1e32a63
- Location:
- uspace/drv
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/usbhub/main.c
r1e32a63 rf9a0cef 50 50 while(true){ 51 51 usb_hub_check_hub_changes(); 52 async_usleep(100 * 1000);52 async_usleep(1000 * 1000); 53 53 } 54 54 return 0; -
uspace/drv/usbhub/usbhub_private.h
r1e32a63 rf9a0cef 182 182 } 183 183 184 static inline int usb_hub_clear_port_feature(int hc, usb_address_t address, 185 int port_index, 186 usb_hub_class_feature_t feature) { 187 usb_target_t target = { 188 .address = address, 189 .endpoint = 0 190 }; 191 usb_device_request_setup_packet_t clear_request = { 192 .request_type = USB_HUB_REQ_TYPE_CLEAR_PORT_FEATURE, 193 .request = USB_DEVREQ_CLEAR_FEATURE, 194 .length = 0, 195 .index = port_index 196 }; 197 clear_request.value = feature; 198 return usb_drv_psync_control_write(hc, target, &clear_request, 199 sizeof(clear_request), NULL, 0); 200 } 201 184 202 185 203 -
uspace/drv/usbhub/utils.c
r1e32a63 rf9a0cef 508 508 int opResult; 509 509 printf("[usb_hub] finalizing add device\n"); 510 opResult = usb_hub_clear_port_feature(hc, target.address, 511 port, USB_HUB_FEATURE_C_PORT_RESET); 512 if (opResult != EOK) { 513 goto release; 514 } 510 515 511 516 /* Request address at from host controller. */ … … 625 630 //something connected/disconnected 626 631 if (usb_port_connect_change(&status)) { 632 opResult = usb_hub_clear_port_feature(hc, target.address, 633 port, USB_HUB_FEATURE_C_PORT_CONNECTION); 634 // TODO: check opResult 627 635 if (usb_port_dev_connected(&status)) { 628 636 printf("[usb_hub] some connection changed\n"); -
uspace/drv/usbkbd/main.c
r1e32a63 rf9a0cef 208 208 209 209 while (true) { 210 async_usleep(10 * 1000);210 async_usleep(1000 * 1000); 211 211 rc = usb_drv_async_interrupt_in(kbd_dev->device->parent_phone, 212 212 poll_target, buffer, BUFFER_SIZE, &actual_size, &handle);
Note:
See TracChangeset
for help on using the changeset viewer.