VirtualBox

Changeset 47420 in vbox


Ignore:
Timestamp:
Jul 26, 2013 11:16:35 AM (11 years ago)
Author:
vboxsync
Message:

Storage: Fix assertion when using the iSCSI backend

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Storage/VD.cpp

    r47026 r47420  
    27712771        rc = pImage->Backend->pfnFlush(pImage->pBackendData, pIoCtx);
    27722772        if (   (   RT_SUCCESS(rc)
    2773                 || rc == VERR_VD_ASYNC_IO_IN_PROGRESS)
     2773                || rc == VERR_VD_ASYNC_IO_IN_PROGRESS
     2774                || rc == VERR_VD_IOCTX_HALT)
    27742775            && pDisk->pCache)
    27752776        {
    27762777            rc = pDisk->pCache->Backend->pfnFlush(pDisk->pCache->pBackendData, pIoCtx);
    27772778            if (   RT_SUCCESS(rc)
    2778                 || rc != VERR_VD_ASYNC_IO_IN_PROGRESS)
     2779                || (   rc != VERR_VD_ASYNC_IO_IN_PROGRESS
     2780                    && rc != VERR_VD_IOCTX_HALT))
    27792781                vdIoCtxUnlockDisk(pDisk, pIoCtx, true /* fProcessBlockedReqs */);
    2780             else
     2782            else if (rc != VERR_VD_IOCTX_HALT)
    27812783                rc = VINF_SUCCESS;
    27822784        }
    27832785        else if (rc == VERR_VD_ASYNC_IO_IN_PROGRESS)
    27842786            rc = VINF_SUCCESS;
    2785         else /* Some other error. */
     2787        else if (rc != VERR_VD_IOCTX_HALT)/* Some other error. */
    27862788            vdIoCtxUnlockDisk(pDisk, pIoCtx, true /* fProcessBlockedReqs */);
    27872789    }
     
    46214623    PVBOXHDD pDisk = pVDIo->pDisk;
    46224624
     4625    LogFlowFunc(("pvUser=%#p pIoCtx=%#p rcReq=%Rrc cbCompleted=%zu\n",
     4626                 pvUser, pIoCtx, rcReq, cbCompleted));
     4627
    46234628    /*
    46244629     * Grab the disk critical section to avoid races with other threads which
     
    46304635     * the request would hang indefinite.
    46314636     */
    4632     pIoCtx->rcReq = rcReq;
     4637    ASMAtomicCmpXchgS32(&pIoCtx->rcReq, rcReq, VINF_SUCCESS);
    46334638    ASMAtomicSubU32(&pIoCtx->Req.Io.cbTransferLeft, cbCompleted);
    46344639
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