- Timestamp:
- May 18, 2015 10:39:35 AM (10 years ago)
- Location:
- trunk/src/VBox/Devices/USB
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/USB/VUSBDevice.cpp
r55337 r55901 1014 1014 PVUSBROOTHUB pRh = vusbDevGetRh(pDev); 1015 1015 AssertPtrReturnVoid(pRh); 1016 if (pDev->u8Address == VUSB_DEFAULT_ADDRESS)1017 pRh->pDefaultAddress = NULL;1018 1016 1019 1017 vusbDevAddressUnHash(pDev); 1020 1018 1021 1019 if (u8Address == VUSB_DEFAULT_ADDRESS) 1022 {1023 if (pRh->pDefaultAddress != NULL)1024 {1025 vusbDevAddressUnHash(pRh->pDefaultAddress);1026 vusbDevSetState(pRh->pDefaultAddress, VUSB_DEVICE_STATE_POWERED);1027 Log(("2 DEFAULT ADDRS\n"));1028 }1029 1030 pRh->pDefaultAddress = pDev;1031 1020 vusbDevSetState(pDev, VUSB_DEVICE_STATE_DEFAULT); 1032 }1033 1021 else 1034 1022 vusbDevSetState(pDev, VUSB_DEVICE_STATE_ADDRESS); … … 1179 1167 ASMAtomicXchgBool(&pDev->fTerminate, false); 1180 1168 rc = RTThreadCreateF(&pDev->hUrbIoThread, vusbDevUrbIoThread, pDev, 0, RTTHREADTYPE_IO, 1181 RTTHREADFLAGS_WAITABLE, "USBDevIo-%d", pDev->i16Port); 1169 RTTHREADFLAGS_WAITABLE, "%s-%d", pDev->pUsbIns->pReg->szName, 1170 pDev->pUsbIns->iInstance); 1182 1171 if (RT_SUCCESS(rc)) 1183 1172 { … … 1233 1222 if (!pRh) 1234 1223 AssertMsgFailedReturn(("Not attached!\n"), VERR_VUSB_DEVICE_NOT_ATTACHED); 1235 if (pRh->pDefaultAddress == pDev)1236 pRh->pDefaultAddress = NULL;1237 1224 1238 1225 pDev->pHub->pOps->pfnDetach(pDev->pHub, pDev); -
trunk/src/VBox/Devices/USB/VUSBInternal.h
r53633 r55901 354 354 /** Address hash table. */ 355 355 PVUSBDEV apAddrHash[VUSB_ADDR_HASHSZ]; 356 /** The default address. */ 357 PVUSBDEV pDefaultAddress; 356 357 #if HC_ARCH_BITS == 32 358 uint32_t Alignment0; 359 #endif 358 360 359 361 /** Pointer to the driver instance. */ … … 365 367 366 368 #if HC_ARCH_BITS == 32 367 uint32_t Alignment0; 368 #endif 369 uint32_t Alignment1; 370 #endif 371 369 372 /** Critical section protecting the device list. */ 370 373 RTCRITSECT CritSectDevices; … … 373 376 374 377 #if HC_ARCH_BITS == 32 375 uint32_t Alignment 1;378 uint32_t Alignment2; 376 379 #endif 377 380
Note:
See TracChangeset
for help on using the changeset viewer.