Changeset 0b68b7c in mainline for uspace/drv/uhci/callback.c


Ignore:
Timestamp:
2011-01-28T17:33:56Z (13 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
3fb3099c
Parents:
b6120d90
Message:

Fixed: initialize arg field properly

Added callback_out call

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/uhci/callback.c

    rb6120d90 r0b68b7c  
    2323        instance->buffer_size = size;
    2424        instance->dev = dev;
     25        instance->arg = arg;
    2526        return EOK;
    2627}
     
    4041        if (instance->callback_in) {
    4142                assert(instance->callback_out == NULL);
     43                uhci_print_verbose("Callback in: %p %x %d.\n",
     44                  instance->callback_in, outcome, act_size);
    4245                instance->callback_in(
    4346                  instance->dev, act_size, outcome, instance->arg);
     47        } else {
     48                assert(instance->callback_out);
     49                assert(instance->callback_in == NULL);
     50                uhci_print_verbose("Callback out: %p %p %x %p .\n",
     51                 instance->callback_out, instance->dev, outcome, instance->arg);
     52                instance->callback_out(
     53                  instance->dev, outcome, instance->arg);
    4454        }
    4555}
Note: See TracChangeset for help on using the changeset viewer.