Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/usbhub/usbhub.c

    r103a3626 r4e8e1f5  
    3636#include <bool.h>
    3737#include <errno.h>
     38#include <str_error.h>
    3839
    3940#include <usb_iface.h>
    4041#include <usb/usbdrv.h>
    4142#include <usb/descriptor.h>
     43#include <usb/recognise.h>
    4244#include <usb/devreq.h>
    4345#include <usb/classes/hub.h>
     
    199201        //ports powered, hub seems to be enabled
    200202
    201         ipc_hangup(hc);
     203        async_hangup(hc);
    202204
    203205        //add the hub to list
     
    317319        }
    318320
     321        devman_handle_t hc_handle;
     322        opResult = usb_drv_find_hc(hub->device, &hc_handle);
     323        if (opResult != EOK) {
     324                usb_log_error("Failed to get handle of host controller: %s.\n",
     325                    str_error(opResult));
     326                return;
     327        }
     328
    319329        devman_handle_t child_handle;
    320         opResult = usb_drv_register_child_in_devman(hc, hub->device,
    321             new_device_address, &child_handle);
     330        opResult = usb_device_register_child_in_devman(new_device_address,
     331            hc_handle, hub->device, &child_handle);
    322332        if (opResult != EOK) {
    323333                dprintf(USB_LOG_LEVEL_ERROR, "could not start driver for new device");
     
    502512                free(change_bitmap);
    503513
    504                 ipc_hangup(hc);
     514                async_hangup(hc);
    505515                fibril_mutex_lock(&usb_hub_list_lock);
    506516        }
Note: See TracChangeset for help on using the changeset viewer.