Changeset 7dfc06fa in mainline for uspace/drv/ohci


Ignore:
Timestamp:
2011-04-08T18:08:46Z (15 years ago)
Author:
Vojtech Horky <vojtechhorky@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
c6cb76d
Parents:
c1b1944
Message:

Do not send max packet size with each transfer

See ticket #177, #121 and partly #49.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/ohci/iface.c

    rc1b1944 r7dfc06fa  
    196196 * @param[in] fun Device function the action was invoked on.
    197197 * @param[in] target Target pipe (address and endpoint number) specification.
    198  * @param[in] max_packet_size Max packet size for the transfer.
    199198 * @param[in] data Data to be sent (in USB endianess, allocated and deallocated
    200199 *      by the caller).
     
    205204 */
    206205static int interrupt_out(
    207     ddf_fun_t *fun, usb_target_t target, size_t max_packet_size, void *data,
     206    ddf_fun_t *fun, usb_target_t target, void *data,
    208207    size_t size, usbhc_iface_transfer_out_callback_t callback, void *arg)
    209208{
    210209        assert(fun);
     210
     211        // FIXME: get from endpoint manager
     212        size_t max_packet_size = 8;
     213
    211214        hc_t *hc = fun_to_hc(fun);
    212215        assert(hc);
     
    239242 * @param[in] fun Device function the action was invoked on.
    240243 * @param[in] target Target pipe (address and endpoint number) specification.
    241  * @param[in] max_packet_size Max packet size for the transfer.
    242244 * @param[in] data Buffer where to store the data (in USB endianess,
    243245 *      allocated and deallocated by the caller).
     
    248250 */
    249251static int interrupt_in(
    250     ddf_fun_t *fun, usb_target_t target, size_t max_packet_size, void *data,
     252    ddf_fun_t *fun, usb_target_t target, void *data,
    251253    size_t size, usbhc_iface_transfer_in_callback_t callback, void *arg)
    252254{
    253255        assert(fun);
     256
     257        // FIXME: get from endpoint manager
     258        size_t max_packet_size = 8;
     259
    254260        hc_t *hc = fun_to_hc(fun);
    255261        assert(hc);
     
    281287 * @param[in] fun Device function the action was invoked on.
    282288 * @param[in] target Target pipe (address and endpoint number) specification.
    283  * @param[in] max_packet_size Max packet size for the transfer.
    284289 * @param[in] data Data to be sent (in USB endianess, allocated and deallocated
    285290 *      by the caller).
     
    290295 */
    291296static int bulk_out(
    292     ddf_fun_t *fun, usb_target_t target, size_t max_packet_size, void *data,
     297    ddf_fun_t *fun, usb_target_t target, void *data,
    293298    size_t size, usbhc_iface_transfer_out_callback_t callback, void *arg)
    294299{
    295300        assert(fun);
     301
     302        // FIXME: get from endpoint manager
     303        size_t max_packet_size = 8;
     304
    296305        hc_t *hc = fun_to_hc(fun);
    297306        assert(hc);
     
    324333 * @param[in] fun Device function the action was invoked on.
    325334 * @param[in] target Target pipe (address and endpoint number) specification.
    326  * @param[in] max_packet_size Max packet size for the transfer.
    327335 * @param[in] data Buffer where to store the data (in USB endianess,
    328336 *      allocated and deallocated by the caller).
     
    333341 */
    334342static int bulk_in(
    335     ddf_fun_t *fun, usb_target_t target, size_t max_packet_size, void *data,
     343    ddf_fun_t *fun, usb_target_t target, void *data,
    336344    size_t size, usbhc_iface_transfer_in_callback_t callback, void *arg)
    337345{
    338346        assert(fun);
     347
     348        // FIXME: get from endpoint manager
     349        size_t max_packet_size = 8;
     350
    339351        hc_t *hc = fun_to_hc(fun);
    340352        assert(hc);
     
    366378 * @param[in] fun Device function the action was invoked on.
    367379 * @param[in] target Target pipe (address and endpoint number) specification.
    368  * @param[in] max_packet_size Max packet size for the transfer.
    369380 * @param[in] setup_packet Setup packet buffer (in USB endianess, allocated
    370381 *      and deallocated by the caller).
     
    378389 */
    379390static int control_write(
    380     ddf_fun_t *fun, usb_target_t target, size_t max_packet_size,
     391    ddf_fun_t *fun, usb_target_t target,
    381392    void *setup_data, size_t setup_size, void *data, size_t size,
    382393    usbhc_iface_transfer_out_callback_t callback, void *arg)
    383394{
    384395        assert(fun);
     396
     397        // FIXME: get from endpoint manager
     398        size_t max_packet_size = 8;
     399
    385400        hc_t *hc = fun_to_hc(fun);
    386401        assert(hc);
     
    417432 * @param[in] fun Device function the action was invoked on.
    418433 * @param[in] target Target pipe (address and endpoint number) specification.
    419  * @param[in] max_packet_size Max packet size for the transfer.
    420434 * @param[in] setup_packet Setup packet buffer (in USB endianess, allocated
    421435 *      and deallocated by the caller).
     
    429443 */
    430444static int control_read(
    431     ddf_fun_t *fun, usb_target_t target, size_t max_packet_size,
     445    ddf_fun_t *fun, usb_target_t target,
    432446    void *setup_data, size_t setup_size, void *data, size_t size,
    433447    usbhc_iface_transfer_in_callback_t callback, void *arg)
    434448{
    435449        assert(fun);
     450
     451        // FIXME: get from endpoint manager
     452        size_t max_packet_size = 8;
     453
    436454        hc_t *hc = fun_to_hc(fun);
    437455        assert(hc);
Note: See TracChangeset for help on using the changeset viewer.