Changeset deece2f in mainline for uspace/drv/vhc/connhost.c


Ignore:
Timestamp:
2011-02-21T22:25:58Z (14 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
233e68d
Parents:
fb78ae72 (diff), dbe25f1 (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:

Development branch merge

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/vhc/connhost.c

    rfb78ae72 rdeece2f  
    3737#include <usb/usb.h>
    3838#include <usb/addrkeep.h>
     39#include <usb/ddfiface.h>
    3940
    4041#include "vhcd.h"
     
    313314static usb_address_keeping_t addresses;
    314315
     316static int tell_address(device_t *dev, devman_handle_t handle,
     317    usb_address_t *address)
     318{
     319        usb_address_t addr = usb_address_keeping_find(&addresses, handle);
     320        if (addr < 0) {
     321                return addr;
     322        }
     323
     324        *address = addr;
     325        return EOK;
     326}
    315327
    316328static int reserve_default_address(device_t *dev, usb_speed_t ignored)
     
    350362}
    351363
    352 static int tell_address(device_t *dev, devman_handle_t handle,
    353     usb_address_t *address)
    354 {
    355         usb_address_t addr = usb_address_keeping_find(&addresses, handle);
    356         if (addr < 0) {
    357                 return addr;
    358         }
    359 
    360         *address = addr;
    361         return EOK;
    362 }
    363 
    364364void address_init(void)
    365365{
     
    368368
    369369usbhc_iface_t vhc_iface = {
    370         .tell_address = tell_address,
    371 
    372370        .reserve_default_address = reserve_default_address,
    373371        .release_default_address = release_default_address,
     
    383381};
    384382
     383usb_iface_t vhc_usb_iface = {
     384        .get_hc_handle = usb_iface_get_hc_handle_hc_impl,
     385        .get_address = tell_address
     386};
     387
     388
    385389/**
    386390 * @}
Note: See TracChangeset for help on using the changeset viewer.