Changeset 9097c16a in mainline for uspace/drv/usbhub/main.c
- Timestamp:
- 2011-02-04T13:14:14Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 9e7cdf8
- Parents:
- 11797d5 (diff), ff244e6 (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. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/usbhub/main.c
r11797d5 r9097c16a 27 27 */ 28 28 29 /** @addtogroup drvusbhub 30 * @{ 31 */ 32 29 33 #include <driver.h> 30 34 #include <errno.h> … … 38 42 39 43 usb_general_list_t usb_hub_list; 40 f utex_t usb_hub_list_lock;44 fibril_mutex_t usb_hub_list_lock; 41 45 42 46 static driver_ops_t hub_driver_ops = { … … 60 64 int main(int argc, char *argv[]) 61 65 { 62 usb_dprintf_enable(NAME,1); 63 futex_initialize(&usb_hub_list_lock, 0); 66 usb_dprintf_enable(NAME, 0); 67 68 fibril_mutex_initialize(&usb_hub_list_lock); 69 fibril_mutex_lock(&usb_hub_list_lock); 64 70 usb_lst_init(&usb_hub_list); 65 futex_up(&usb_hub_list_lock); 71 fibril_mutex_unlock(&usb_hub_list_lock); 72 66 73 fid_t fid = fibril_create(usb_hub_control_loop, NULL); 67 74 if (fid == 0) { 68 dprintf(1, "failed to start fibril for HUB devices");69 //printf("%s: failed to start fibril for HUB devices\n", NAME);75 fprintf(stderr, NAME ": failed to start monitoring fibril," \ 76 " driver aborting.\n"); 70 77 return ENOMEM; 71 78 } … … 74 81 return driver_main(&hub_driver); 75 82 } 83 84 /** 85 * @} 86 */ 87
Note:
See TracChangeset
for help on using the changeset viewer.