Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset b21dfba in mainline


Ignore:
Timestamp:
2011-07-11T17:05:18Z (10 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master
Children:
f20bc82
Parents:
00694c5
Message:

libusbhost: Make batch_finish a wrapper over finish_error rather the otherr way around.

Location:
uspace/lib/usbhost
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/usbhost/include/usb/host/batch.h

    r00694c5 rb21dfba  
    9393void usb_transfer_batch_call_in_and_dispose(usb_transfer_batch_t *instance);
    9494void usb_transfer_batch_call_out_and_dispose(usb_transfer_batch_t *instance);
    95 void usb_transfer_batch_finish(usb_transfer_batch_t *instance);
     95void usb_transfer_batch_finish_error(usb_transfer_batch_t *instance, int error);
    9696void usb_transfer_batch_dispose(usb_transfer_batch_t *instance);
    9797
    98 static inline void usb_transfer_batch_finish_error(
    99     usb_transfer_batch_t *instance, int error)
     98static inline void usb_transfer_batch_finish(usb_transfer_batch_t *instance)
    10099{
    101100        assert(instance);
    102         instance->error = error;
    103         usb_transfer_batch_finish(instance);
     101        usb_transfer_batch_finish_error(instance, EOK);
    104102}
    105103
  • uspace/lib/usbhost/src/batch.c

    r00694c5 rb21dfba  
    105105 *
    106106 */
    107 void usb_transfer_batch_finish(usb_transfer_batch_t *instance)
     107void usb_transfer_batch_finish_error(usb_transfer_batch_t *instance, int error)
    108108{
    109109        assert(instance);
    110110        assert(instance->ep);
    111111        assert(instance->next_step);
     112        instance->error = error;
    112113        endpoint_release(instance->ep);
    113114        instance->next_step(instance);
Note: See TracChangeset for help on using the changeset viewer.