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

Changeset f6b2a76 in mainline


Ignore:
Timestamp:
2013-01-25T22:20:20Z (9 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master
Children:
c39e9fb
Parents:
ffa254f1
Message:

libusbdev: Add name getting wrapper.

Location:
uspace/lib/usbdev
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/usbdev/include/usb/dev/driver.h

    rffa254f1 rf6b2a76  
    171171void usb_device_deinit(usb_device_t *);
    172172
     173const char* usb_device_get_name(usb_device_t *);
     174
    173175async_exch_t * usb_device_bus_exchange_begin(usb_device_t *);
    174176void usb_device_bus_exchange_end(async_exch_t *);
  • uspace/lib/usbdev/src/devdrv.c

    rffa254f1 rf6b2a76  
    521521}
    522522
     523const char *usb_device_get_name(usb_device_t *usb_dev)
     524{
     525        assert(usb_dev);
     526        assert(usb_dev->ddf_dev);
     527        //TODO Handle case without ddf_dev
     528        return ddf_dev_get_name(usb_dev->ddf_dev);
     529}
     530
    523531async_exch_t * usb_device_bus_exchange_begin(usb_device_t *usb_dev)
    524532{
  • uspace/lib/usbdev/src/devpoll.c

    rffa254f1 rf6b2a76  
    8080                usb_log_debug("Poll%p: started polling of `%s' - " \
    8181                    "interface %d (%s,%d,%d), %zuB/%zu.\n",
    82                     data, ddf_dev_get_name(data->dev->ddf_dev),
     82                    data, usb_device_get_name(data->dev),
    8383                    (int) mapping->interface->interface_number,
    8484                    usb_str_class(mapping->interface->interface_class),
     
    159159                if (failed) {
    160160                        usb_log_error("Polling of device `%s' terminated: "
    161                             "recurring failures.\n", ddf_dev_get_name(
    162                             data->dev->ddf_dev));
     161                            "recurring failures.\n",
     162                            usb_device_get_name(data->dev));
    163163                } else {
    164164                        usb_log_debug("Polling of device `%s' terminated: "
    165                             "driver request.\n", ddf_dev_get_name(
    166                             data->dev->ddf_dev));
     165                            "driver request.\n",
     166                            usb_device_get_name(data->dev));
    167167                }
    168168        }
Note: See TracChangeset for help on using the changeset viewer.