Changeset 56e9fb0 in mainline
- Timestamp:
- 2011-09-14T18:52:40Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 365e29e2
- Parents:
- 8e3d17f
- Location:
- uspace
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/uhci/uhci_batch.c
r8e3d17f r56e9fb0 229 229 uhci_batch->usb_batch->ep->speed == USB_SPEED_LOW; 230 230 const size_t mps = uhci_batch->usb_batch->ep->max_packet_size; 231 const usb_target_t target = { 231 const usb_target_t target = {{ 232 232 uhci_batch->usb_batch->ep->address, 233 uhci_batch->usb_batch->ep->endpoint } ;233 uhci_batch->usb_batch->ep->endpoint }}; 234 234 235 235 int toggle = endpoint_toggle_get(uhci_batch->usb_batch->ep); … … 289 289 uhci_batch->usb_batch->ep->speed == USB_SPEED_LOW; 290 290 const size_t mps = uhci_batch->usb_batch->ep->max_packet_size; 291 const usb_target_t target = { 291 const usb_target_t target = {{ 292 292 uhci_batch->usb_batch->ep->address, 293 uhci_batch->usb_batch->ep->endpoint } ;293 uhci_batch->usb_batch->ep->endpoint }}; 294 294 295 295 /* setup stage */ -
uspace/lib/drv/generic/remote_usbhc.c
r8e3d17f r56e9fb0 239 239 240 240 usb_target_t target = { 241 .address = DEV_IPC_GET_ARG1(*call),242 .endpoint = DEV_IPC_GET_ARG2(*call) 241 {.address = DEV_IPC_GET_ARG1(*call), 242 .endpoint = DEV_IPC_GET_ARG2(*call) } 243 243 }; 244 244 size_t data_buffer_len = DEV_IPC_GET_ARG3(*call); … … 302 302 } 303 303 304 usb_target_t target = { 304 usb_target_t target = {{ 305 305 .address = DEV_IPC_GET_ARG1(*call), 306 306 .endpoint = DEV_IPC_GET_ARG2(*call) 307 } ;307 }}; 308 308 309 309 int rc; … … 436 436 } 437 437 438 const usb_target_t target = { 438 const usb_target_t target = {{ 439 439 .address = DEV_IPC_GET_ARG1(*call), 440 440 .endpoint = DEV_IPC_GET_ARG2(*call) 441 } ;441 }}; 442 442 443 443 … … 484 484 } 485 485 486 const usb_target_t target = { 486 const usb_target_t target = {{ 487 487 .address = DEV_IPC_GET_ARG1(*call), 488 488 .endpoint = DEV_IPC_GET_ARG2(*call) 489 } ;489 }}; 490 490 491 491 -
uspace/lib/usb/include/usb/hc.h
r8e3d17f r56e9fb0 62 62 devman_handle_t *); 63 63 64 int usb_hc_get_address_by_handle(devman_handle_t);64 usb_address_t usb_hc_get_address_by_handle(devman_handle_t); 65 65 66 66 int usb_hc_find(devman_handle_t, devman_handle_t *); -
uspace/lib/usb/include/usb/usb.h
r8e3d17f r56e9fb0 106 106 * Negative values could be used to indicate error. 107 107 */ 108 typedef int usb_address_t;108 typedef int16_t usb_address_t; 109 109 110 110 /** Default USB address. */ … … 116 116 * Negative values could be used to indicate error. 117 117 */ 118 typedef int usb_endpoint_t;118 typedef int16_t usb_endpoint_t; 119 119 120 120 /** Maximum endpoint number in USB 1.1. … … 126 126 * Pair address + endpoint is identification of transaction recipient. 127 127 */ 128 typedef struct { 129 usb_address_t address; 130 usb_endpoint_t endpoint; 128 typedef union { 129 struct { 130 usb_address_t address; 131 usb_endpoint_t endpoint; 132 } __attribute__((packed)); 133 uint32_t packed; 131 134 } usb_target_t; 132 135 -
uspace/lib/usbhost/src/batch.c
r8e3d17f r56e9fb0 136 136 if (instance->ep->transfer_type == USB_TRANSFER_CONTROL 137 137 && instance->error == EOK) { 138 usb_target_t target =139 { instance->ep->address, instance->ep->endpoint};138 const usb_target_t target = 139 {{ instance->ep->address, instance->ep->endpoint }}; 140 140 reset_ep_if_need( 141 141 fun_to_hcd(instance->fun), target, instance->setup_buffer);
Note:
See TracChangeset
for help on using the changeset viewer.