VirtualBox

Changeset 40500 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Mar 16, 2012 2:40:07 PM (13 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
76884
Message:

Keep track of medium lock state.

File:
1 edited

Legend:

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

    r38844 r40500  
    3636{
    3737    /** Core LUN structure */
    38     VSCSILUNINT    Core;
     38    VSCSILUNINT     Core;
    3939    /** Size of the virtual disk. */
    40     uint64_t       cSectors;
     40    uint64_t        cSectors;
    4141    /** Sector size. */
    42     uint32_t       cbSector;
     42    uint32_t        cbSector;
     43    /** Medium locked indicator. */
     44    bool            fLocked;
    4345} VSCSILUNMMC, *PVSCSILUNMMC;
    4446
     
    263265            break;
    264266        }
     267        case SCSI_PREVENT_ALLOW_MEDIUM_REMOVAL:
     268        {
     269            pVScsiLunMmc->fLocked = pVScsiReq->pbCDB[4] & 1;
     270            rcReq = vscsiLunReqSenseOkSet(pVScsiLun, pVScsiReq);
     271            break;
     272        }
     273
    265274        default:
    266275            //AssertMsgFailed(("Command %#x [%s] not implemented\n", pRequest->pbCDB[0], SCSICmdText(pRequest->pbCDB[0])));
Note: See TracChangeset for help on using the changeset viewer.

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