VirtualBox

Changeset 52517 in vbox for trunk/src/VBox/Devices/USB


Ignore:
Timestamp:
Aug 28, 2014 3:18:46 PM (10 years ago)
Author:
vboxsync
Message:

Devices/USB: Fix crash on Linux hosts, a hang when disconnecting a USB device while there is a transfer active and crash upon VM termination if a device with isochronous input endpoints was attached to the VM

Location:
trunk/src/VBox/Devices/USB
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/USB/VUSBDevice.cpp

    r52513 r52517  
    12281228        vusbMsgFreeExtraData(pDev->aPipes[i].pCtrl);
    12291229        RTCritSectDelete(&pDev->aPipes[i].CritSectCtrl);
     1230
     1231        if (pDev->aPipes[i].hReadAhead)
     1232        {
     1233            vusbReadAheadStop(pDev->aPipes[i].hReadAhead);
     1234            pDev->aPipes[i].hReadAhead = NULL;
     1235        }
    12301236    }
    12311237    memset(pDev->aPipes, 0, sizeof(pDev->aPipes));
     
    16091615        rc = RTReqQueueCallV(pDev->hReqQueueSync, &hReq, 0 /* cMillies */, fReqFlags, pfnFunction, cArgs, Args);
    16101616        Assert(RT_SUCCESS(rc) || rc == VERR_TIMEOUT);
     1617
    16111618        vusbDevUrbIoThreadWakeup(pDev);
    1612 
    1613         if (fFlags & VUSB_DEV_IO_THREAD_EXEC_FLAGS_SYNC)
     1619        if (   rc == VERR_TIMEOUT
     1620            && (fFlags & VUSB_DEV_IO_THREAD_EXEC_FLAGS_SYNC))
    16141621        {
    16151622            rc = RTReqWait(hReq, RT_INDEFINITE_WAIT);
    16161623            AssertRC(rc);
    16171624        }
     1625        RTReqRelease(hReq);
    16181626    }
    16191627    else
  • trunk/src/VBox/Devices/USB/linux/USBProxyDevice-linux.cpp

    r52386 r52517  
    16531653        {
    16541654            /* unlink from the pending delivery list */
    1655             RTListNodeRemove(&pDevLnx->ListTaxing);
     1655            RTListNodeRemove(&pUrbLnx->NodeList);
    16561656
    16571657            /* temporarily into the active list, so free works right. */
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette