Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/vhc/hub/virthub.c

    r1da979d r9d58539  
    3434 */
    3535#include <usb/classes/classes.h>
    36 #include <usb/classes/hub.h>
    3736#include <usbvirt/device.h>
    3837#include <assert.h>
    3938#include <errno.h>
    4039#include <str_error.h>
    41 #include <stdio.h>
    4240#include <assert.h>
    4341#include <stdlib.h>
     
    7876        .type = USB_DESCTYPE_HUB,
    7977        .port_count = HUB_PORT_COUNT,
    80         .characteristics = HUB_CHAR_NO_POWER_SWITCH_FLAG | HUB_CHAR_NO_OC_FLAG,
     78        .characteristics = 0,
    8179        .power_on_warm_up = 50, /* Huh? */
    8280        .max_current = 100, /* Huh again. */
     
    9997        .length = sizeof(usb_standard_configuration_descriptor_t),
    10098        .descriptor_type = USB_DESCTYPE_CONFIGURATION,
    101         .total_length =
     99        .total_length = 
    102100                sizeof(usb_standard_configuration_descriptor_t)
    103101                + sizeof(std_interface_descriptor)
     
    147145 * @return Error code.
    148146 */
    149 int virthub_init(usbvirt_device_t *dev, const char* name)
     147int virthub_init(usbvirt_device_t *dev)
    150148{
    151149        if (dev == NULL) {
     
    154152        dev->ops = &hub_ops;
    155153        dev->descriptors = &descriptors;
    156         dev->address = 0;
    157         dev->name = str_dup(name);
    158         if (!dev->name)
    159                 return ENOMEM;
    160154
    161155        hub_t *hub = malloc(sizeof(hub_t));
    162156        if (hub == NULL) {
    163                 free(dev->name);
    164157                return ENOMEM;
    165158        }
Note: See TracChangeset for help on using the changeset viewer.