Changeset 3bd96bb in mainline for uspace/drv/uhci-hcd/batch.c


Ignore:
Timestamp:
2011-03-13T23:23:42Z (14 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
17ceb72
Parents:
f123909
Message:

Move scheduling to iface functions

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/uhci-hcd/batch.c

    rf123909 r3bd96bb  
    4545#define DEFAULT_ERROR_COUNT 3
    4646
    47 static int batch_schedule(batch_t *instance);
    48 
    4947static void batch_control(batch_t *instance,
    5048    usb_packet_id data_stage, usb_packet_id status_stage);
     
    5452static void batch_call_in_and_dispose(batch_t *instance);
    5553static void batch_call_out_and_dispose(batch_t *instance);
    56 static void batch_dispose(batch_t *instance);
    5754
    5855
     
    203200        instance->next_step = batch_call_out_and_dispose;
    204201        usb_log_debug("Batch(%p) CONTROL WRITE initialized.\n", instance);
    205         batch_schedule(instance);
    206202}
    207203/*----------------------------------------------------------------------------*/
     
    216212        instance->next_step = batch_call_in_and_dispose;
    217213        usb_log_debug("Batch(%p) CONTROL READ initialized.\n", instance);
    218         batch_schedule(instance);
    219214}
    220215/*----------------------------------------------------------------------------*/
     
    229224        instance->next_step = batch_call_in_and_dispose;
    230225        usb_log_debug("Batch(%p) INTERRUPT IN initialized.\n", instance);
    231         batch_schedule(instance);
    232226}
    233227/*----------------------------------------------------------------------------*/
     
    244238        instance->next_step = batch_call_out_and_dispose;
    245239        usb_log_debug("Batch(%p) INTERRUPT OUT initialized.\n", instance);
    246         batch_schedule(instance);
    247240}
    248241/*----------------------------------------------------------------------------*/
     
    257250        instance->next_step = batch_call_in_and_dispose;
    258251        usb_log_debug("Batch(%p) BULK IN initialized.\n", instance);
    259         batch_schedule(instance);
    260252}
    261253/*----------------------------------------------------------------------------*/
     
    271263        instance->next_step = batch_call_out_and_dispose;
    272264        usb_log_debug("Batch(%p) BULK OUT initialized.\n", instance);
    273         batch_schedule(instance);
    274265}
    275266/*----------------------------------------------------------------------------*/
     
    446437        free(instance);
    447438}
    448 /*----------------------------------------------------------------------------*/
    449 int batch_schedule(batch_t *instance)
    450 {
    451         assert(instance);
    452         uhci_hc_t *hc = fun_to_uhci_hc(instance->fun);
    453         assert(hc);
    454         return uhci_hc_schedule(hc, instance);
    455 }
    456439/**
    457440 * @}
Note: See TracChangeset for help on using the changeset viewer.