VirtualBox

Changeset 33015 in vbox


Ignore:
Timestamp:
Oct 8, 2010 5:45:16 PM (14 years ago)
Author:
vboxsync
Message:

SCSI: Log errors of completed requests

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Storage/DrvSCSI.cpp

    r32983 r33015  
    225225        VSCSIIoReqCompleted(hVScsiIoReq, rc, false /* fRedoPossible */);
    226226    else
     227    {
     228        uint64_t  uOffset    = 0;
     229        size_t    cbTransfer = 0;
     230        size_t    cbSeg      = 0;
     231        PCRTSGSEG paSeg      = NULL;
     232        unsigned  cSeg       = 0;
     233
     234        VSCSIIoReqParamsGet(hVScsiIoReq, &uOffset, &cbTransfer,
     235                            &cSeg, &cbSeg, &paSeg);
     236
     237        pThis->cErrors++;
     238        if (   pThis->cErrors < MAX_LOG_REL_ERRORS
     239            && enmTxDir == VSCSIIOREQTXDIR_FLUSH)
     240            LogRel(("SCSI#%u: Flush returned rc=%Rrc\n",
     241                    pThis->pDrvIns->iInstance, rc));
     242        else
     243            LogRel(("SCSI#%u: %s at offset %llu (%u bytes left) returned rc=%Rrc\n",
     244                    pThis->pDrvIns->iInstance,
     245                    enmTxDir == VSCSIIOREQTXDIR_READ
     246                    ? "Read"
     247                    : "Write",
     248                    uOffset,
     249                    cbTransfer, rc));
     250
    227251        VSCSIIoReqCompleted(hVScsiIoReq, rc, drvscsiIsRedoPossible(rc));
     252    }
    228253
    229254    return VINF_SUCCESS;
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