Changeset d083126 in mainline for uspace/drv/bus/usb/usbhub/usbhub.h


Ignore:
Timestamp:
2011-10-13T13:20:26Z (13 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
3a5506a
Parents:
cff3fb6 (diff), 22a2b763 (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:

Merge initial USB unplug support.

Support device_remove and device_gone in libusbdev.
usbhub and uhcirh try to unbind and destroy functions of attached devices.
add unplug support for usbhub driver (only works on empty hubs as there is no support in other drivers).

Drivers to go:

usbmid
usbflbk
usbhid
usbmast
usbmouse

Tested on:

qemu UHCI and emulated hub,
ICH8 hw and Alcor Micro Corp. USB Hub

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/usbhub/usbhub.h

    rcff3fb6 rd083126  
    5252
    5353/** Information about attached hub. */
    54 struct usb_hub_info_t {
     54struct usb_hub_dev {
    5555        /** Number of ports. */
    5656        size_t port_count;
    57 
    58         /** Attached device handles, for each port one */
     57        /** Port structures, one for each port */
    5958        usb_hub_port_t *ports;
    60 
    6159        /** Connection to hcd */
    6260        usb_hc_connection_t connection;
    63 
    6461        /** Generic usb device data*/
    6562        usb_device_t *usb_device;
     
    7673        /** Condition variable for pending_ops_count. */
    7774        fibril_condvar_t pending_ops_cv;
     75        /** Pointer to devman usbhub function. */
     76        ddf_fun_t *hub_fun;
     77        /** Status indicator */
     78        bool running;
    7879};
    7980
    80 int usb_hub_add_device(usb_device_t *usb_dev);
     81int usb_hub_device_add(usb_device_t *usb_dev);
     82int usb_hub_device_gone(usb_device_t *usb_dev);
    8183
    8284bool hub_port_changes_callback(usb_device_t *dev,
Note: See TracChangeset for help on using the changeset viewer.