Changes in uspace/drv/uhci/main.c [71ed4849:2972e21] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/uhci/main.c
r71ed4849 r2972e21 1 1 /* 2 * Copyright (c) 2010 Vojtech Horky 2 * Copyright (c) 2010 Vojtech Horky, Jan Vesely 3 3 * All rights reserved. 4 4 * … … 27 27 */ 28 28 #include <usb/hcdhubd.h> 29 #include <usb_iface.h>30 #include <usb/debug.h>31 29 #include <errno.h> 32 #include <driver.h> 30 31 #include "debug.h" 32 #include "iface.h" 33 #include "name.h" 33 34 #include "uhci.h" 34 35 35 static int usb_iface_get_hc_handle(device_t *dev, devman_handle_t *handle)36 {37 /* This shall be called only for the UHCI itself. */38 assert(dev->parent == NULL);39 40 *handle = dev->handle;41 return EOK;42 }43 44 static usb_iface_t hc_usb_iface = {45 .get_hc_handle = usb_iface_get_hc_handle46 };47 36 48 37 static device_ops_t uhci_ops = { 49 .interfaces[USB_DEV_IFACE] = &hc_usb_iface, 50 .interfaces[USBHC_DEV_IFACE] = &uhci_iface 38 .interfaces[USBHC_DEV_IFACE] = &uhci_iface, 51 39 }; 52 40 53 41 static int uhci_add_device(device_t *device) 54 42 { 55 usb_dprintf(NAME, 1, "uhci_add_device() called\n"); 43 // usb_dprintf(NAME, DEBUG, "uhci_add_device() called\n"); 44 uhci_print_info( "uhci_add_device() called\n" ); 56 45 device->ops = &uhci_ops; 57 46 58 /* 59 * We need to announce the presence of our root hub. 60 */ 61 usb_dprintf(NAME, 2, "adding root hub\n"); 62 usb_hcd_add_root_hub(device); 47 uhci_init( device, (void*)0xc020 ); 63 48 64 49 return EOK; … … 79 64 * Do some global initializations. 80 65 */ 81 sleep( 5);82 usb_dprintf_enable(NAME, 5);66 sleep( 5 ); 67 usb_dprintf_enable(NAME, DEBUG_LEVEL_MAX); 83 68 84 69 return driver_main(&uhci_driver);
Note:
See TracChangeset
for help on using the changeset viewer.