Changeset b36e5de2 in mainline for uspace/drv/uhci-hcd/iface.c
- Timestamp:
- 2011-02-18T20:14:26Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 374552ef
- Parents:
- 228f251
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/uhci-hcd/iface.c
r228f251 rb36e5de2 164 164 return EOK; 165 165 } 166 /*----------------------------------------------------------------------------*/167 static int control_write_setup(device_t *dev, usb_target_t target,168 size_t max_packet_size,169 void *data, size_t size,170 usbhc_iface_transfer_out_callback_t callback, void *arg)171 {172 dev_speed_t speed = FULL_SPEED;173 166 174 usb_log_warning("Using deprecated API %s.\n", __FUNCTION__);175 batch_t *batch = batch_get(dev, target, USB_TRANSFER_CONTROL,176 max_packet_size, speed, NULL, 0, data, size, NULL, callback, arg);177 if (!batch)178 return ENOMEM;179 batch_control_setup_old(batch);180 return EOK;181 }182 /*----------------------------------------------------------------------------*/183 static int control_write_data(device_t *dev, usb_target_t target,184 size_t max_packet_size,185 void *data, size_t size,186 usbhc_iface_transfer_out_callback_t callback, void *arg)187 {188 dev_speed_t speed = FULL_SPEED;189 167 190 usb_log_warning("Using deprecated API %s.\n", __FUNCTION__);191 batch_t *batch = batch_get(dev, target, USB_TRANSFER_CONTROL,192 max_packet_size, speed, data, size, NULL, 0, NULL, callback, arg);193 if (!batch)194 return ENOMEM;195 batch_control_write_data_old(batch);196 return EOK;197 }198 /*----------------------------------------------------------------------------*/199 static int control_write_status(device_t *dev, usb_target_t target,200 usbhc_iface_transfer_in_callback_t callback, void *arg)201 {202 size_t max_packet_size = 8;203 dev_speed_t speed = FULL_SPEED;204 205 usb_log_warning("Using deprecated API %s.\n", __FUNCTION__);206 batch_t *batch = batch_get(dev, target, USB_TRANSFER_CONTROL,207 max_packet_size, speed, NULL, 0, NULL, 0, callback, NULL, arg);208 if (!batch)209 return ENOMEM;210 batch_control_write_status_old(batch);211 return EOK;212 }213 /*----------------------------------------------------------------------------*/214 static int control_read_setup(device_t *dev, usb_target_t target,215 size_t max_packet_size,216 void *data, size_t size,217 usbhc_iface_transfer_out_callback_t callback, void *arg)218 {219 dev_speed_t speed = FULL_SPEED;220 221 usb_log_warning("Using deprecated API %s.\n", __FUNCTION__);222 batch_t *batch = batch_get(dev, target, USB_TRANSFER_CONTROL,223 max_packet_size, speed, NULL, 0, data, size, NULL, callback, arg);224 if (!batch)225 return ENOMEM;226 batch_control_setup_old(batch);227 return EOK;228 }229 /*----------------------------------------------------------------------------*/230 static int control_read_data(device_t *dev, usb_target_t target,231 size_t max_packet_size,232 void *data, size_t size,233 usbhc_iface_transfer_in_callback_t callback, void *arg)234 {235 dev_speed_t speed = FULL_SPEED;236 237 usb_log_warning("Using deprecated API %s.\n", __FUNCTION__);238 batch_t *batch = batch_get(dev, target, USB_TRANSFER_CONTROL,239 max_packet_size, speed, data, size, NULL, 0, callback, NULL, arg);240 if (!batch)241 return ENOMEM;242 batch_control_read_data_old(batch);243 return EOK;244 }245 /*----------------------------------------------------------------------------*/246 static int control_read_status(device_t *dev, usb_target_t target,247 usbhc_iface_transfer_out_callback_t callback, void *arg)248 {249 size_t max_packet_size = 8;250 dev_speed_t speed = FULL_SPEED;251 252 usb_log_warning("Using deprecated API %s.\n", __FUNCTION__);253 batch_t *batch = batch_get(dev, target, USB_TRANSFER_CONTROL,254 max_packet_size, speed, NULL, 0, NULL, 0, NULL, callback, arg);255 if (!batch)256 return ENOMEM;257 batch_control_read_status_old(batch);258 return EOK;259 }260 168 /*----------------------------------------------------------------------------*/ 261 169 usbhc_iface_t uhci_iface = { … … 273 181 .control_read = control_read, 274 182 .control_write = control_write, 275 276 .control_write_setup = control_write_setup,277 .control_write_data = control_write_data,278 .control_write_status = control_write_status,279 280 .control_read_setup = control_read_setup,281 .control_read_data = control_read_data,282 .control_read_status = control_read_status283 183 }; 284 184 /**
Note:
See TracChangeset
for help on using the changeset viewer.