Changeset e0ba26b in mainline


Ignore:
Timestamp:
2011-01-25T19:20:26Z (14 years ago)
Author:
Vojtech Horky <vojtechhorky@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
192a0063
Parents:
a088d15 (diff), 68a68705 (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:

Merged vojtechhorky/ - various fixes

The merge includes following changes

  • USB transaction outcome is propagated to clients
  • virtual host controller handles device unplugging
  • Doxygen documentation fixes
Location:
uspace
Files:
46 edited

Legend:

Unmodified
Added
Removed
  • uspace/doc/doxygroups.h

    ra088d15 re0ba26b  
    176176         * @brief Library for creating USB devices drivers.
    177177         */
     178
     179         /**
     180          * @defgroup usbhub USB hub driver
     181          * @ingroup usb
     182          * @brief USB hub driver.
     183          */
     184          */
     185
  • uspace/drv/usbhub/main.c

    ra088d15 re0ba26b  
    6060int main(int argc, char *argv[])
    6161{
    62         usb_dprintf_enable(NAME,1);
     62        usb_dprintf_enable(NAME, 0);
     63
    6364        futex_initialize(&usb_hub_list_lock, 0);
    6465        usb_lst_init(&usb_hub_list);
    6566        futex_up(&usb_hub_list_lock);
     67
    6668        fid_t fid = fibril_create(usb_hub_control_loop, NULL);
    6769        if (fid == 0) {
    68                 dprintf(1, "failed to start fibril for HUB devices");
    69                 //printf("%s: failed to start fibril for HUB devices\n", NAME);
     70                fprintf(stderr, NAME ": failed to start monitoring fibril," \
     71                    " driver aborting.\n");
    7072                return ENOMEM;
    7173        }
  • uspace/drv/usbhub/usbhub.c

    ra088d15 re0ba26b  
    2626 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    2727 */
    28 /** @addtogroup usb hub driver
     28/** @addtogroup usbhub
    2929 * @{
    3030 */
     
    7676        //get some hub info
    7777        usb_address_t addr = usb_drv_get_my_address(hc, device);
    78         dprintf(1,"[usb_hub] address of newly created hub = %d", addr);
     78        dprintf(1, "address of newly created hub = %d", addr);
    7979        /*if(addr<0){
    8080                //return result;
     
    100100
    101101        if (opResult != EOK) {
    102                 dprintf(1,"[usb_hub] failed when receiving hub descriptor, badcode = %d",opResult);
     102                dprintf(1, "failed when receiving hub descriptor, badcode = %d",opResult);
    103103                free(serialized_descriptor);
    104104                return result;
     
    107107        descriptor = usb_deserialize_hub_desriptor(serialized_descriptor);
    108108        if(descriptor==NULL){
    109                 dprintf(1,"[usb_hub] could not deserialize descriptor ");
     109                dprintf(1, "could not deserialize descriptor ");
    110110                result->port_count = 1;///\TODO this code is only for debug!!!
    111111                return result;
     
    127127        //finish
    128128
    129         dprintf(1,"[usb_hub] hub info created");
     129        dprintf(1, "hub info created");
    130130
    131131        return result;
     
    134134int usb_add_hub_device(device_t *dev) {
    135135        dprintf(1, "add_hub_device(handle=%d)", (int) dev->handle);
    136         dprintf(1,"[usb_hub] hub device");
     136        dprintf(1, "hub device");
    137137
    138138        /*
     
    162162        usb_standard_device_descriptor_t std_descriptor;
    163163        opResult = usb_drv_req_get_device_descriptor(hc, target.address,
    164     &std_descriptor);
     164            &std_descriptor);
    165165        if(opResult!=EOK){
    166                 dprintf(1,"[usb_hub] could not get device descriptor, %d",opResult);
     166                dprintf(1, "could not get device descriptor, %d",opResult);
    167167                return opResult;
    168168        }
    169         dprintf(1,"[usb_hub] hub has %d configurations",std_descriptor.configuration_count);
     169        dprintf(1, "hub has %d configurations",std_descriptor.configuration_count);
    170170        if(std_descriptor.configuration_count<1){
    171                 dprintf(1,"[usb_hub] THERE ARE NO CONFIGURATIONS AVAILABLE");
     171                dprintf(1, "THERE ARE NO CONFIGURATIONS AVAILABLE");
    172172                //shouldn`t I return?
    173173        }
     
    178178        &config_descriptor);
    179179        if(opResult!=EOK){
    180                 dprintf(1,"[usb_hub] could not get configuration descriptor, %d",opResult);
     180                dprintf(1, "could not get configuration descriptor, %d",opResult);
    181181                return opResult;
    182182        }
     
    186186
    187187        if (opResult != EOK) {
    188                 dprintf(1,"[usb_hub]something went wrong when setting hub`s configuration, %d", opResult);
     188                dprintf(1, "something went wrong when setting hub`s configuration, %d", opResult);
    189189        }
    190190
     
    193193                usb_hub_set_power_port_request(&request, port);
    194194                opResult = usb_drv_sync_control_write(hc, target, &request, NULL, 0);
    195                 dprintf(1,"[usb_hub] powering port %d",port);
     195                dprintf(1, "powering port %d",port);
    196196                if (opResult != EOK) {
    197                         dprintf(1,"[usb_hub]something went wrong when setting hub`s %dth port", port);
     197                        dprintf(1, "something went wrong when setting hub`s %dth port", port);
    198198                }
    199199        }
     
    207207        futex_up(&usb_hub_list_lock);
    208208
    209         dprintf(1,"[usb_hub] hub info added to list");
     209        dprintf(1, "hub info added to list");
    210210        //(void)hub_info;
    211211        usb_hub_check_hub_changes();
     
    213213       
    214214
    215         dprintf(1,"[usb_hub] hub dev added");
    216         dprintf(1,"\taddress %d, has %d ports ",
     215        dprintf(1, "hub dev added");
     216        dprintf(1, "\taddress %d, has %d ports ",
    217217                        hub_info->usb_device->address,
    218218                        hub_info->port_count);
    219         dprintf(1,"\tused configuration %d",config_descriptor.configuration_number);
     219        dprintf(1, "\tused configuration %d",config_descriptor.configuration_number);
    220220
    221221        return EOK;
     
    238238inline static int usb_hub_release_default_address(int hc){
    239239        int opResult;
    240         dprintf(1,"[usb_hub] releasing default address");
     240        dprintf(1, "releasing default address");
    241241        opResult = usb_drv_release_default_address(hc);
    242242        if (opResult != EOK) {
    243                 dprintf(1,"[usb_hub] failed to release default address");
     243                dprintf(1, "failed to release default address");
    244244        }
    245245        return opResult;
     
    255255        usb_device_request_setup_packet_t request;
    256256        int opResult;
    257         dprintf(1,"[usb_hub] some connection changed");
     257        dprintf(1, "some connection changed");
    258258        //get default address
    259259        opResult = usb_drv_reserve_default_address(hc);
    260260        if (opResult != EOK) {
    261                 dprintf(1,"[usb_hub] cannot assign default address, it is probably used");
     261                dprintf(1, "cannot assign default address, it is probably used");
    262262                return;
    263263        }
     
    270270                        );
    271271        if (opResult != EOK) {
    272                 dprintf(1,"[usb_hub] something went wrong when reseting a port");
     272                dprintf(1, "something went wrong when reseting a port");
    273273                usb_hub_release_default_address(hc);
    274274        }
     
    285285
    286286        int opResult;
    287         dprintf(1,"[usb_hub] finalizing add device");
     287        dprintf(1, "finalizing add device");
    288288        opResult = usb_hub_clear_port_feature(hc, target.address,
    289289            port, USB_HUB_FEATURE_C_PORT_RESET);
    290290        if (opResult != EOK) {
    291                 dprintf(1,"[usb_hub] failed to clear port reset feature");
     291                dprintf(1, "failed to clear port reset feature");
    292292                usb_hub_release_default_address(hc);
    293293                return;
     
    297297        usb_address_t new_device_address = usb_drv_request_address(hc);
    298298        if (new_device_address < 0) {
    299                 dprintf(1,"[usb_hub] failed to get free USB address");
     299                dprintf(1, "failed to get free USB address");
    300300                opResult = new_device_address;
    301301                usb_hub_release_default_address(hc);
    302302                return;
    303303        }
    304         dprintf(1,"[usb_hub] setting new address");
     304        dprintf(1, "setting new address");
    305305        opResult = usb_drv_req_set_address(hc, USB_ADDRESS_DEFAULT,
    306306            new_device_address);
    307307
    308308        if (opResult != EOK) {
    309                 dprintf(1,"[usb_hub] could not set address for new device");
     309                dprintf(1, "could not set address for new device");
    310310                usb_hub_release_default_address(hc);
    311311                return;
     
    322322            new_device_address, &child_handle);
    323323        if (opResult != EOK) {
    324                 dprintf(1,"[usb_hub] could not start driver for new device");
     324                dprintf(1, "could not start driver for new device");
    325325                return;
    326326        }
     
    330330        opResult = usb_drv_bind_address(hc, new_device_address, child_handle);
    331331        if (opResult != EOK) {
    332                 dprintf(1,"[usb_hub] could not assign address of device in hcd");
    333                 return;
    334         }
    335         dprintf(1,"[usb_hub] new device address %d, handle %zu",
     332                dprintf(1, "could not assign address of device in hcd");
     333                return;
     334        }
     335        dprintf(1, "new device address %d, handle %zu",
    336336            new_device_address, child_handle);
    337337
     
    358358                opResult = usb_drv_release_address(hc,hub->attached_devs[port].address);
    359359                if(opResult != EOK) {
    360                         dprintf(1,
    361                                         "[usb_hub] could not release address of removed device: %d"
    362                                         ,opResult);
     360                        dprintf(1, "could not release address of " \
     361                            "removed device: %d", opResult);
    363362                }
    364363                hub->attached_devs[port].address = 0;
    365364        }else{
    366                 dprintf(1,
    367                                 "[usb_hub] this is strange, disconnected device had no address");
     365                dprintf(1, "this is strange, disconnected device had no address");
    368366                //device was disconnected before it`s port was reset - return default address
    369367                usb_drv_release_default_address(hc);
     
    379377static void usb_hub_process_interrupt(usb_hub_info_t * hub, int hc,
    380378        uint16_t port, usb_address_t address) {
    381         dprintf(1,"[usb_hub] interrupt at port %d", port);
     379        dprintf(1, "interrupt at port %d", port);
    382380        //determine type of change
    383381        usb_target_t target;
     
    397395                        );
    398396        if (opResult != EOK) {
    399                 dprintf(1,"[usb_hub] ERROR: could not get port status");
     397                dprintf(1, "ERROR: could not get port status");
    400398                return;
    401399        }
    402400        if (rcvd_size != sizeof (usb_port_status_t)) {
    403                 dprintf(1,"[usb_hub] ERROR: received status has incorrect size");
     401                dprintf(1, "ERROR: received status has incorrect size");
    404402                return;
    405403        }
     
    410408                // TODO: check opResult
    411409                if (usb_port_dev_connected(&status)) {
    412                         dprintf(1,"[usb_hub] some connection changed");
     410                        dprintf(1, "some connection changed");
    413411                        usb_hub_init_add_device(hc, port, target);
    414412                } else {
     
    418416        //port reset
    419417        if (usb_port_reset_completed(&status)) {
    420                 dprintf(1,"[usb_hub] port reset complete");
     418                dprintf(1, "port reset complete");
    421419                if (usb_port_enabled(&status)) {
    422420                        usb_hub_finalize_add_device(hub, hc, port, target);
    423421                } else {
    424                         dprintf(1,"[usb_hub] ERROR: port reset, but port still not enabled");
     422                        dprintf(1, "ERROR: port reset, but port still not enabled");
    425423                }
    426424        }
     
    431429        usb_port_set_dev_connected(&status, false);
    432430        if (status>>16) {
    433                 dprintf(1,"[usb_hub]there was some unsupported change on port %d: %X",port,status);
     431                dprintf(1, "there was some unsupported change on port %d: %X",port,status);
    434432
    435433        }
     
    460458                target.address = hub_info->usb_device->address;
    461459                target.endpoint = 1;/// \TODO get from endpoint descriptor
    462                 /*dprintf(1,"[usb_hub] checking changes for hub at addr %d",
    463                     target.address);*/
     460                dprintf(1, "checking changes for hub at addr %d",
     461                    target.address);
    464462
    465463                size_t port_count = hub_info->port_count;
     
    490488
    491489                if (opResult != EOK) {
    492                         dprintf(1,"[usb_hub] something went wrong while getting status of hub");
     490                        dprintf(1, "something went wrong while getting status of hub");
    493491                        continue;
    494492                }
  • uspace/drv/usbhub/usblist.c

    ra088d15 re0ba26b  
    2626 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    2727 */
    28 /** @addtogroup usb hub driver
     28/** @addtogroup usbhub
    2929 * @{
    3030 */
  • uspace/drv/usbhub/usblist.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 
    30 #ifndef USBLIST_H
    31 #define USBLIST_H
    32 /** @addtogroup usb hub driver
     29/** @addtogroup usbhub
    3330 * @{
    3431 */
     
    4037 * much simpler and more straight-forward semantics.
    4138 */
     39#ifndef USBLIST_H
     40#define USBLIST_H
    4241
    4342/**
     
    7877}
    7978
    80 
     79#endif  /* USBLIST_H */
    8180/**
    8281 * @}
    8382 */
    84 
    85 
    86 
    87 #endif  /* USBLIST_H */
    88 
  • uspace/drv/usbhub/utils.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup usbhub
    3030 * @{
    3131 */
  • uspace/drv/vhc/conn.h

    ra088d15 re0ba26b  
    5151
    5252void default_connection_handler(device_t *, ipc_callid_t, ipc_call_t *);
     53void on_client_close(device_t *);
    5354
    5455
  • uspace/drv/vhc/conndev.c

    ra088d15 re0ba26b  
    8888                int callback = IPC_GET_ARG5(*icall);
    8989                virtdev_connection_t *dev
    90                     = virtdev_add_device(callback);
     90                    = virtdev_add_device(callback, (sysarg_t)fibril_get_id());
    9191                if (!dev) {
    9292                        ipc_answer_0(icallid, EEXISTS);
     
    9999                int rc = get_device_name(callback, devname, DEVICE_NAME_MAXLENGTH);
    100100
    101                 dprintf(0, "virtual device connected (name: %s)",
    102                     rc == EOK ? devname : "<unknown>");
    103 
    104                 /* FIXME: destroy the device when the client disconnects. */
     101                dprintf(0, "virtual device connected (name: %s, id: %x)",
     102                    rc == EOK ? devname : "<unknown>", dev->id);
    105103
    106104                return;
     
    110108}
    111109
     110/** Callback for DDF when client disconnects.
     111 *
     112 * @param d Device the client was connected to.
     113 */
     114void on_client_close(device_t *d)
     115{
     116        /*
     117         * Maybe a virtual device is being unplugged.
     118         */
     119        virtdev_connection_t *dev = virtdev_find((sysarg_t)fibril_get_id());
     120        if (dev == NULL) {
     121                return;
     122        }
     123
     124        dprintf(0, "virtual device disconnected (id: %x)", dev->id);
     125        virtdev_destroy_device(dev);
     126}
     127
    112128
    113129/**
  • uspace/drv/vhc/devices.c

    ra088d15 re0ba26b  
    5858/** Create virtual device.
    5959 *
    60  * @param address USB address.
    6160 * @param phone Callback phone.
     61 * @param id Device id.
    6262 * @return New device.
    63  * @retval NULL Out of memory or address already occupied.
    64  */
    65 virtdev_connection_t *virtdev_add_device(int phone)
     63 * @retval NULL Out of memory.
     64 */
     65virtdev_connection_t *virtdev_add_device(int phone, sysarg_t id)
    6666{
    6767        virtdev_connection_t *dev = (virtdev_connection_t *)
    6868            malloc(sizeof(virtdev_connection_t));
     69        if (dev == NULL) {
     70                return NULL;
     71        }
     72
    6973        dev->phone = phone;
     74        dev->id = id;
    7075        list_append(&dev->link, &devices);
    7176       
     
    7378       
    7479        return dev;
     80}
     81
     82/** Find virtual device by id.
     83 *
     84 * @param id Device id.
     85 * @return Device with given id.
     86 * @retval NULL No such device.
     87 */
     88virtdev_connection_t *virtdev_find(sysarg_t id)
     89{
     90        link_t *pos;
     91        list_foreach(pos, &devices) {
     92                virtdev_connection_t *dev
     93                    = list_get_instance(pos, virtdev_connection_t, link);
     94                if (dev->id == id) {
     95                        return dev;
     96                }
     97        }
     98
     99        return NULL;
    75100}
    76101
     
    90115usb_transaction_outcome_t virtdev_send_to_all(transaction_t *transaction)
    91116{
     117        /* For easier debugging. */
     118        switch (transaction->type) {
     119                case USBVIRT_TRANSACTION_SETUP:
     120                case USBVIRT_TRANSACTION_OUT:
     121                        transaction->actual_len = transaction->len;
     122                        break;
     123                case USBVIRT_TRANSACTION_IN:
     124                        transaction->actual_len = 0;
     125                        break;
     126                default:
     127                        assert(false && "unreachable branch in switch()");
     128        }
     129        usb_transaction_outcome_t outcome = USB_OUTCOME_BABBLE;
     130
    92131        link_t *pos;
    93132        list_foreach(pos, &devices) {
     
    140179                        transaction->actual_len = IPC_GET_ARG1(answer_data);
    141180                        rc = (int)answer_rc;
     181                }
     182
     183                /*
     184                 * If at least one device was able to accept this
     185                 * transaction and process it, we can announce success.
     186                 */
     187                if (rc == EOK) {
     188                        outcome = USB_OUTCOME_OK;
    142189                }
    143190        }
     
    165212                                    transaction->buffer, transaction->len,
    166213                                    &tmp);
    167                                 if (tmp < transaction->len) {
    168                                         transaction->len = tmp;
    169                                 }
     214                                transaction->actual_len = tmp;
    170215                                break;
    171216                               
     
    178223                }
    179224                dprintf(4, "transaction on hub processed...");
     225                outcome = USB_OUTCOME_OK;
    180226        }
    181227       
     
    184230         * real-life image.
    185231         */
    186         return USB_OUTCOME_OK;
     232        return outcome;
    187233}
    188234
  • uspace/drv/vhc/devices.h

    ra088d15 re0ba26b  
    4545        /** Phone used when sending data to device. */
    4646        int phone;
     47        /** Unique identification. */
     48        sysarg_t id;
    4749        /** Linked-list handle. */
    4850        link_t link;
    4951} virtdev_connection_t;
    5052
    51 virtdev_connection_t *virtdev_add_device(int);
    52 virtdev_connection_t *virtdev_get_mine(void);
     53virtdev_connection_t *virtdev_add_device(int, sysarg_t);
     54virtdev_connection_t *virtdev_find(sysarg_t);
    5355void virtdev_destroy_device(virtdev_connection_t *);
    5456usb_transaction_outcome_t virtdev_send_to_all(transaction_t *);
  • uspace/drv/vhc/hcd.c

    ra088d15 re0ba26b  
    6969        .interfaces[USBHC_DEV_IFACE] = &vhc_iface,
    7070        .interfaces[USB_DEV_IFACE] = &hc_usb_iface,
     71        .close = on_client_close,
    7172        .default_handler = default_connection_handler
    7273};
  • uspace/drv/vhc/hub/hub.c

    ra088d15 re0ba26b  
    155155}
    156156
     157/** Disconnects a device from a hub.
     158 *
     159 * @param hub Hub the device was connected to.
     160 * @param device Device to be disconnected.
     161 * @return Error code.
     162 */
     163int hub_disconnect_device(hub_t *hub, void *device)
     164{
     165        size_t index = hub_find_device(hub, device);
     166        if (index == (size_t) -1) {
     167                return ENOENT;
     168        }
     169
     170        hub_port_t *port = &hub->ports[index];
     171
     172        port->connected_device = NULL;
     173        port->state = HUB_PORT_STATE_DISCONNECTED;
     174        set_port_status_change(port, HUB_STATUS_C_PORT_CONNECTION);
     175
     176        return EOK;
     177}
     178
    157179/** Find port device is connected to.
    158180 *
     
    173195        }
    174196
    175         return 0;
     197        return -1;
    176198}
    177199
  • uspace/drv/vhc/hub/hub.h

    ra088d15 re0ba26b  
    9494void hub_init(hub_t *);
    9595size_t hub_connect_device(hub_t *, void *);
     96int hub_disconnect_device(hub_t *, void *);
    9697size_t hub_find_device(hub_t *, void *);
    9798void hub_acquire(hub_t *);
  • uspace/drv/vhc/hub/virthub.c

    ra088d15 re0ba26b  
    203203
    204204        hub_acquire(hub);
    205         /* TODO: implement. */
     205        hub_disconnect_device(hub, conn);
    206206        hub_release(hub);
    207207
  • uspace/lib/drv/generic/remote_usbhc.c

    ra088d15 re0ba26b  
    243243
    244244        // FIXME - answer according to outcome
    245         ipc_answer_0(trans->caller, EOK);
     245        ipc_answer_0(trans->caller, outcome);
    246246
    247247        free(trans);
     
    254254
    255255        // FIXME - answer according to outcome
    256         ipc_answer_1(trans->caller, EOK, (sysarg_t)trans);
     256        ipc_answer_1(trans->caller, outcome, (sysarg_t)trans);
    257257
    258258        trans->size = actual_size;
  • uspace/lib/drv/include/usb_iface.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libdrv usb
     29/** @addtogroup libdrv
     30 * @addtogroup usb
    3031 * @{
    3132 */
  • uspace/lib/drv/include/usbhc_iface.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libdrv usb
     29/** @addtogroup libdrv
     30 * @addtogroup usb
    3031 * @{
    3132 */
  • uspace/lib/usb/include/usb/classes/classes.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/include/usb/classes/hid.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/include/usb/classes/hidparser.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/include/usb/classes/hidut.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/include/usb/classes/hidutkbd.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/include/usb/classes/hub.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
     
    6868 *      For more information see Universal Serial Bus Specification Revision 1.1 chapter 11.16.2
    6969 */
    70 typedef struct hub_descriptor_type{
     70typedef struct usb_hub_descriptor_type {
    7171    /** Number of bytes in this descriptor, including this byte */
    7272    //uint8_t bDescLength;
  • uspace/lib/usb/include/usb/debug.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
     
    4545
    4646#endif
     47/**
     48 * @}
     49 */
     50
  • uspace/lib/usb/include/usb/descriptor.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/include/usb/devreq.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/include/usb/hcd.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
     
    8181    devman_handle_t);
    8282
    83 
    8483#endif
     84/**
     85 * @}
     86 */
  • uspace/lib/usb/include/usb/hcdhubd.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/include/usb/usb.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/include/usb/usbdrv.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/addrkeep.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/class.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/debug.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/dp.c

    ra088d15 re0ba26b  
    4545 * @param data Parser data.
    4646 * @param ptr Pointer to be verified.
    47  * @return Whether @ptr points inside <code>data->data</code> field.
     47 * @return Whether @p ptr points inside <code>data->data</code> field.
    4848 */
    4949static bool is_valid_descriptor_pointer(usb_dp_parser_data_t *data,
  • uspace/lib/usb/src/drvpsync.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/hcdhubd.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/hcdhubd_private.h

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/hcdrv.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/hidparser.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/localdrv.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/recognise.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
     
    3939#include <errno.h>
    4040
     41/** Callback for getting host controller handle.
     42 *
     43 * @param dev Device in question.
     44 * @param[out] handle Devman handle of the host controller.
     45 * @return Error code.
     46 */
    4147static int usb_iface_get_hc_handle(device_t *dev, devman_handle_t *handle)
    4248{
     
    237243 * @param matches Match ids list to add matches to.
    238244 * @param address USB address of the attached device.
     245 * @param config_count Number of configurations the device has.
    239246 * @return Error code.
    240247 */
     
    342349/** Probe for device kind and register it in devman.
    343350 *
    344  * @param hc Open phone to the host controller.
    345  * @param parent Parent device.
    346  * @param address Address of the (unknown) attached device.
     351 * @param[in] hc Open phone to the host controller.
     352 * @param[in] parent Parent device.
     353 * @param[in] address Address of the (unknown) attached device.
     354 * @param[out] child_handle Handle of the child device.
    347355 * @return Error code.
    348356 */
  • uspace/lib/usb/src/remotedrv.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/usb.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/usbdrv.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
  • uspace/lib/usb/src/usbdrvreq.c

    ra088d15 re0ba26b  
    2727 */
    2828
    29 /** @addtogroup libusb usb
     29/** @addtogroup libusb
    3030 * @{
    3131 */
     
    188188 * @param[in] phone Open phone to HC driver.
    189189 * @param[in] old_address Current address.
    190  * @param[in] address Address to be set.
     190 * @param[in] new_address Address to be set.
    191191 * @return Error code.
    192192 */
  • uspace/lib/usbvirt/src/main.c

    ra088d15 re0ba26b  
    183183/** Create necessary phones for communication with virtual HCD.
    184184 * This function wraps following calls:
    185  * -# open <code>/dev/devices/\\virt\\usbhc for reading
     185 * -# open <code>/dev/devices/\\virt\\usbhc</code> for reading
    186186 * -# access phone of file opened in previous step
    187187 * -# create callback through just opened phone
Note: See TracChangeset for help on using the changeset viewer.