Changeset f11c288 in mainline for uspace/lib/usb/src/host/endpoint.c


Ignore:
Timestamp:
2011-04-09T22:20:02Z (13 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
0748854, d32ed36
Parents:
709e868 (diff), a19a2d7 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Fix crash on endpoint_t instance removal

Remove unused default address handling (support in device_keeper_t will be removed later)
Add tons of OHCI debug output (still not working), and some fixes found by using that debug output.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/usb/src/host/endpoint.c

    r709e868 rf11c288  
    5353        fibril_mutex_initialize(&instance->guard);
    5454        fibril_condvar_initialize(&instance->avail);
    55         link_initialize(&instance->same_device_eps);
    5655        return EOK;
    5756}
     
    6160        assert(instance);
    6261        assert(!instance->active);
    63         list_remove(&instance->same_device_eps);
    6462        free(instance);
    6563}
     
    9795}
    9896/*----------------------------------------------------------------------------*/
    99 void endpoint_toggle_reset(link_t *ep)
     97void endpoint_toggle_reset_filtered(endpoint_t *instance, usb_target_t target)
    10098{
    101         endpoint_t *instance =
    102             list_get_instance(ep, endpoint_t, same_device_eps);
    10399        assert(instance);
    104         instance->toggle = 0;
    105 }
    106 /*----------------------------------------------------------------------------*/
    107 void endpoint_toggle_reset_filtered(link_t *ep, usb_endpoint_t epn)
    108 {
    109         endpoint_t *instance =
    110             list_get_instance(ep, endpoint_t, same_device_eps);
    111         assert(instance);
    112         if (instance->endpoint == epn)
     100        if (instance->address == target.address &&
     101            instance->endpoint == target.endpoint)
    113102                instance->toggle = 0;
    114103}
Note: See TracChangeset for help on using the changeset viewer.