Changeset 44533 in vbox
- Timestamp:
- Feb 4, 2013 8:55:12 PM (12 years ago)
- Location:
- trunk/src/VBox
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Storage/DevBusLogic.cpp
r44532 r44533 797 797 unsigned char uLegacyQueueTag : 2; 798 798 /** The SCSI CDB. (A CDB can be 12 bytes long.) */ 799 uint8_t a CDB[12];799 uint8_t abCDB[12]; 800 800 /** Reserved. */ 801 801 uint8_t uReserved3[6]; … … 840 840 uint8_t aReserved[2]; 841 841 /** The SCSI CDB. (A CDB can be 12 bytes long.) */ 842 uint8_t a CDB[12];842 uint8_t abCDB[12]; 843 843 } CCB24, *PCCB24; 844 844 AssertCompileSize(CCB24, 30); … … 869 869 uint8_t aPad2[2]; 870 870 /** The SCSI CDB (up to 12 bytes). */ 871 uint8_t a CDB[12];871 uint8_t abCDB[12]; 872 872 } CCBC, *PCCBC; 873 873 AssertCompileSize(CCB24, 30); … … 880 880 AssertCompileMemberOffset(CCB24, uHostAdapterStatus, 14); 881 881 AssertCompileMemberOffset(CCB32, uHostAdapterStatus, 14); 882 AssertCompileMemberOffset(CCBC, a CDB, 18);883 AssertCompileMemberOffset(CCB24, a CDB, 18);884 AssertCompileMemberOffset(CCB32, a CDB, 18);882 AssertCompileMemberOffset(CCBC, abCDB, 18); 883 AssertCompileMemberOffset(CCB24, abCDB, 18); 884 AssertCompileMemberOffset(CCB32, abCDB, 18); 885 885 886 886 /** A union of all CCB types (24-bit/32-bit/common). */ … … 930 930 uint8_t cbCDB; 931 931 /** The SCSI CDB. (A CDB can be 12 bytes long.) */ 932 uint8_t a CDB[12];932 uint8_t abCDB[12]; 933 933 } ESCMD, *PESCMD; 934 934 AssertCompileSize(ESCMD, 24); … … 1286 1286 Log(("%s: PhysAddrSenseData=%#x\n", __FUNCTION__, pCCB->n.u32PhysAddrSenseData)); 1287 1287 } 1288 Log(("%s: uCDB[0]=%#x\n", __FUNCTION__, pCCB->c.a CDB[0]));1288 Log(("%s: uCDB[0]=%#x\n", __FUNCTION__, pCCB->c.abCDB[0])); 1289 1289 for (int i = 1; i < pCCB->c.cbCDB; i++) 1290 Log(("%s: uCDB[%d]=%u\n", __FUNCTION__, i, pCCB->c.a CDB[i]));1290 Log(("%s: uCDB[%d]=%u\n", __FUNCTION__, i, pCCB->c.abCDB[i])); 1291 1291 } 1292 1292 … … 1493 1493 * returns no data, hence the buffer must be left alone! 1494 1494 */ 1495 if (pTaskState->CommandControlBlockGuest.c.a CDB[0] == 0)1495 if (pTaskState->CommandControlBlockGuest.c.abCDB[0] == 0) 1496 1496 cbDataCCB = 0; 1497 1497 #endif … … 1621 1621 { 1622 1622 GCPhysAddrSenseBuffer = pTaskState->MailboxGuest.u32PhysAddrCCB; 1623 GCPhysAddrSenseBuffer += pTaskState->CommandControlBlockGuest.c.cbCDB + RT_OFFSETOF(CCB24, a CDB);1623 GCPhysAddrSenseBuffer += pTaskState->CommandControlBlockGuest.c.cbCDB + RT_OFFSETOF(CCB24, abCDB); 1624 1624 } 1625 1625 else … … 2401 2401 ScsiInquiryData.u3PeripheralQualifier = SCSI_INQUIRY_DATA_PERIPHERAL_QUALIFIER_NOT_CONNECTED_NOT_SUPPORTED; 2402 2402 2403 memcpy(pBusLogic->VBoxSCSI.p Buf, &ScsiInquiryData, 5);2403 memcpy(pBusLogic->VBoxSCSI.pbBuf, &ScsiInquiryData, 5); 2404 2404 2405 2405 rc = vboxscsiRequestFinished(&pBusLogic->VBoxSCSI, &pTaskState->PDMScsiRequest, SCSI_STATUS_OK); … … 2855 2855 2856 2856 pTaskState->PDMScsiRequest.cbCDB = pTaskState->CommandControlBlockGuest.c.cbCDB; 2857 pTaskState->PDMScsiRequest.pbCDB = pTaskState->CommandControlBlockGuest.c.a CDB;2857 pTaskState->PDMScsiRequest.pbCDB = pTaskState->CommandControlBlockGuest.c.abCDB; 2858 2858 if (pTaskState->DataSeg.cbSeg) 2859 2859 { … … 3116 3116 SSMR3PutU8 (pSSM, pBusLogic->VBoxSCSI.uTxDir); 3117 3117 SSMR3PutU8 (pSSM, pBusLogic->VBoxSCSI.cbCDB); 3118 SSMR3PutMem (pSSM, pBusLogic->VBoxSCSI.a CDB, sizeof(pBusLogic->VBoxSCSI.aCDB));3118 SSMR3PutMem (pSSM, pBusLogic->VBoxSCSI.abCDB, sizeof(pBusLogic->VBoxSCSI.abCDB)); 3119 3119 SSMR3PutU8 (pSSM, pBusLogic->VBoxSCSI.iCDB); 3120 3120 SSMR3PutU32 (pSSM, pBusLogic->VBoxSCSI.cbBuf); … … 3123 3123 SSMR3PutU8 (pSSM, pBusLogic->VBoxSCSI.enmState); 3124 3124 if (pBusLogic->VBoxSCSI.cbBuf) 3125 SSMR3PutMem(pSSM, pBusLogic->VBoxSCSI.p Buf, pBusLogic->VBoxSCSI.cbBuf);3125 SSMR3PutMem(pSSM, pBusLogic->VBoxSCSI.pbBuf, pBusLogic->VBoxSCSI.cbBuf); 3126 3126 3127 3127 /* … … 3226 3226 SSMR3GetU8 (pSSM, &pBusLogic->VBoxSCSI.uTxDir); 3227 3227 SSMR3GetU8 (pSSM, &pBusLogic->VBoxSCSI.cbCDB); 3228 SSMR3GetMem (pSSM, pBusLogic->VBoxSCSI.a CDB, sizeof(pBusLogic->VBoxSCSI.aCDB));3228 SSMR3GetMem (pSSM, pBusLogic->VBoxSCSI.abCDB, sizeof(pBusLogic->VBoxSCSI.abCDB)); 3229 3229 SSMR3GetU8 (pSSM, &pBusLogic->VBoxSCSI.iCDB); 3230 3230 SSMR3GetU32 (pSSM, &pBusLogic->VBoxSCSI.cbBuf); … … 3234 3234 if (pBusLogic->VBoxSCSI.cbBuf) 3235 3235 { 3236 pBusLogic->VBoxSCSI.p Buf = (uint8_t *)RTMemAllocZ(pBusLogic->VBoxSCSI.cbBuf);3237 if (!pBusLogic->VBoxSCSI.p Buf)3236 pBusLogic->VBoxSCSI.pbBuf = (uint8_t *)RTMemAllocZ(pBusLogic->VBoxSCSI.cbBuf); 3237 if (!pBusLogic->VBoxSCSI.pbBuf) 3238 3238 { 3239 3239 LogRel(("BusLogic: Out of memory during restore.\n")); … … 3241 3241 N_("BusLogic: Out of memory during restore\n")); 3242 3242 } 3243 SSMR3GetMem(pSSM, pBusLogic->VBoxSCSI.p Buf, pBusLogic->VBoxSCSI.cbBuf);3243 SSMR3GetMem(pSSM, pBusLogic->VBoxSCSI.pbBuf, pBusLogic->VBoxSCSI.cbBuf); 3244 3244 } 3245 3245 -
trunk/src/VBox/Devices/Storage/DevLsiLogicSCSI.cpp
r43665 r44533 3726 3726 ScsiInquiryData.u3PeripheralQualifier = SCSI_INQUIRY_DATA_PERIPHERAL_QUALIFIER_NOT_CONNECTED_NOT_SUPPORTED; 3727 3727 3728 memcpy(pLsiLogic->VBoxSCSI.p Buf, &ScsiInquiryData, 5);3728 memcpy(pLsiLogic->VBoxSCSI.pbBuf, &ScsiInquiryData, 5); 3729 3729 3730 3730 rc = vboxscsiRequestFinished(&pLsiLogic->VBoxSCSI, &pTaskState->PDMScsiRequest, SCSI_STATUS_OK); … … 4254 4254 SSMR3PutU8 (pSSM, pLsiLogic->VBoxSCSI.uTxDir); 4255 4255 SSMR3PutU8 (pSSM, pLsiLogic->VBoxSCSI.cbCDB); 4256 SSMR3PutMem (pSSM, pLsiLogic->VBoxSCSI.a CDB, sizeof(pLsiLogic->VBoxSCSI.aCDB));4256 SSMR3PutMem (pSSM, pLsiLogic->VBoxSCSI.abCDB, sizeof(pLsiLogic->VBoxSCSI.abCDB)); 4257 4257 SSMR3PutU8 (pSSM, pLsiLogic->VBoxSCSI.iCDB); 4258 4258 SSMR3PutU32 (pSSM, pLsiLogic->VBoxSCSI.cbBuf); … … 4261 4261 SSMR3PutU8 (pSSM, pLsiLogic->VBoxSCSI.enmState); 4262 4262 if (pLsiLogic->VBoxSCSI.cbBuf) 4263 SSMR3PutMem(pSSM, pLsiLogic->VBoxSCSI.p Buf, pLsiLogic->VBoxSCSI.cbBuf);4263 SSMR3PutMem(pSSM, pLsiLogic->VBoxSCSI.pbBuf, pLsiLogic->VBoxSCSI.cbBuf); 4264 4264 4265 4265 return SSMR3PutU32(pSSM, ~0); … … 4536 4536 SSMR3GetU8 (pSSM, &pLsiLogic->VBoxSCSI.uTxDir); 4537 4537 SSMR3GetU8 (pSSM, &pLsiLogic->VBoxSCSI.cbCDB); 4538 SSMR3GetMem (pSSM, pLsiLogic->VBoxSCSI.a CDB, sizeof(pLsiLogic->VBoxSCSI.aCDB));4538 SSMR3GetMem (pSSM, pLsiLogic->VBoxSCSI.abCDB, sizeof(pLsiLogic->VBoxSCSI.abCDB)); 4539 4539 SSMR3GetU8 (pSSM, &pLsiLogic->VBoxSCSI.iCDB); 4540 4540 SSMR3GetU32 (pSSM, &pLsiLogic->VBoxSCSI.cbBuf); … … 4544 4544 if (pLsiLogic->VBoxSCSI.cbBuf) 4545 4545 { 4546 pLsiLogic->VBoxSCSI.p Buf = (uint8_t *)RTMemAllocZ(pLsiLogic->VBoxSCSI.cbBuf);4547 if (!pLsiLogic->VBoxSCSI.p Buf)4546 pLsiLogic->VBoxSCSI.pbBuf = (uint8_t *)RTMemAllocZ(pLsiLogic->VBoxSCSI.cbBuf); 4547 if (!pLsiLogic->VBoxSCSI.pbBuf) 4548 4548 { 4549 4549 LogRel(("LsiLogic: Out of memory during restore.\n")); … … 4551 4551 N_("LsiLogic: Out of memory during restore\n")); 4552 4552 } 4553 SSMR3GetMem(pSSM, pLsiLogic->VBoxSCSI.p Buf, pLsiLogic->VBoxSCSI.cbBuf);4553 SSMR3GetMem(pSSM, pLsiLogic->VBoxSCSI.pbBuf, pLsiLogic->VBoxSCSI.cbBuf); 4554 4554 } 4555 4555 -
trunk/src/VBox/Devices/Storage/VBoxSCSI.cpp
r44528 r44533 1 1 /* $Id$ */ 2 2 /** @file 3 * 4 * VBox storage devices: 5 * Simple SCSI interface for BIOS access 3 * VBox storage devices - Simple SCSI interface for BIOS access. 6 4 */ 7 5 8 6 /* 9 * Copyright (C) 2006-201 2Oracle Corporation7 * Copyright (C) 2006-2013 Oracle Corporation 10 8 * 11 9 * This file is part of VirtualBox Open Source Edition (OSE), as … … 22 20 *******************************************************************************/ 23 21 //#define DEBUG 24 #define LOG_GROUP LOG_GROUP_DEV_BUSLOGIC /* @todo:Create extra group. */22 #define LOG_GROUP LOG_GROUP_DEV_BUSLOGIC /** @todo Create extra group. */ 25 23 26 24 #if defined(IN_R0) || defined(IN_RC) 27 # error This device has no R0 or GC components25 # error This device has no R0 or RC components 28 26 #endif 29 27 … … 37 35 #include "VBoxSCSI.h" 38 36 37 38 /** 39 * Resets the state. 40 */ 39 41 static void vboxscsiReset(PVBOXSCSI pVBoxSCSI) 40 42 { 41 43 pVBoxSCSI->regIdentify = 0; 42 44 pVBoxSCSI->cbCDB = 0; 43 memset(pVBoxSCSI->a CDB, 0, sizeof(pVBoxSCSI->aCDB));45 memset(pVBoxSCSI->abCDB, 0, sizeof(pVBoxSCSI->abCDB)); 44 46 pVBoxSCSI->iCDB = 0; 45 47 pVBoxSCSI->fBusy = false; … … 48 50 pVBoxSCSI->cbBuf = 0; 49 51 pVBoxSCSI->iBuf = 0; 50 if (pVBoxSCSI->p Buf)51 RTMemFree(pVBoxSCSI->p Buf);52 53 pVBoxSCSI->p Buf= NULL;52 if (pVBoxSCSI->pbBuf) 53 RTMemFree(pVBoxSCSI->pbBuf); 54 55 pVBoxSCSI->pbBuf = NULL; 54 56 pVBoxSCSI->enmState = VBOXSCSISTATE_NO_COMMAND; 55 57 } … … 63 65 int vboxscsiInitialize(PVBOXSCSI pVBoxSCSI) 64 66 { 65 pVBoxSCSI->p Buf= NULL;67 pVBoxSCSI->pbBuf = NULL; 66 68 vboxscsiReset(pVBoxSCSI); 67 69 … … 102 104 if ((pVBoxSCSI->enmState == VBOXSCSISTATE_COMMAND_READY) && pVBoxSCSI->cbBuf > 0) 103 105 { 104 AssertMsg(pVBoxSCSI->p Buf, ("pBuf is NULL\n"));106 AssertMsg(pVBoxSCSI->pbBuf, ("pBuf is NULL\n")); 105 107 Assert(pVBoxSCSI->enmState == VBOXSCSISTATE_COMMAND_READY); 106 108 Assert(!pVBoxSCSI->fBusy); 107 uVal = pVBoxSCSI->p Buf[pVBoxSCSI->iBuf];109 uVal = pVBoxSCSI->pbBuf[pVBoxSCSI->iBuf]; 108 110 pVBoxSCSI->iBuf++; 109 111 pVBoxSCSI->cbBuf--; … … 113 115 * Clear everything and reset command buffer. 114 116 */ 115 RTMemFree(pVBoxSCSI->p Buf);116 pVBoxSCSI->p Buf= NULL;117 RTMemFree(pVBoxSCSI->pbBuf); 118 pVBoxSCSI->pbBuf = NULL; 117 119 pVBoxSCSI->cbCDB = 0; 118 120 pVBoxSCSI->iCDB = 0; … … 121 123 pVBoxSCSI->uTargetDevice = 0; 122 124 pVBoxSCSI->enmState = VBOXSCSISTATE_NO_COMMAND; 123 memset(pVBoxSCSI->a CDB, 0, sizeof(pVBoxSCSI->aCDB));125 memset(pVBoxSCSI->abCDB, 0, sizeof(pVBoxSCSI->abCDB)); 124 126 } 125 127 } … … 202 204 else if (pVBoxSCSI->enmState == VBOXSCSISTATE_READ_COMMAND) 203 205 { 204 pVBoxSCSI->a CDB[pVBoxSCSI->iCDB] = uVal;206 pVBoxSCSI->abCDB[pVBoxSCSI->iCDB] = uVal; 205 207 pVBoxSCSI->iCDB++; 206 208 … … 213 215 { 214 216 /* This is a write allocate buffer. */ 215 pVBoxSCSI->p Buf = (uint8_t *)RTMemAllocZ(pVBoxSCSI->cbBuf);216 if (!pVBoxSCSI->p Buf)217 pVBoxSCSI->pbBuf = (uint8_t *)RTMemAllocZ(pVBoxSCSI->cbBuf); 218 if (!pVBoxSCSI->pbBuf) 217 219 return VERR_NO_MEMORY; 218 220 } … … 239 241 else 240 242 { 241 pVBoxSCSI->p Buf[pVBoxSCSI->iBuf++] = uVal;243 pVBoxSCSI->pbBuf[pVBoxSCSI->iBuf++] = uVal; 242 244 if (pVBoxSCSI->iBuf == pVBoxSCSI->cbBuf) 243 245 { … … 287 289 if (pVBoxSCSI->uTxDir == VBOXSCSI_TXDIR_FROM_DEVICE) 288 290 { 289 if (pVBoxSCSI->p Buf)290 RTMemFree(pVBoxSCSI->p Buf);291 292 pVBoxSCSI->p Buf = (uint8_t *)RTMemAllocZ(pVBoxSCSI->cbBuf);293 if (!pVBoxSCSI->p Buf)291 if (pVBoxSCSI->pbBuf) 292 RTMemFree(pVBoxSCSI->pbBuf); 293 294 pVBoxSCSI->pbBuf = (uint8_t *)RTMemAllocZ(pVBoxSCSI->cbBuf); 295 if (!pVBoxSCSI->pbBuf) 294 296 return VERR_NO_MEMORY; 295 297 } … … 299 301 if (!pScsiRequest->paScatterGatherHead) 300 302 { 301 RTMemFree(pVBoxSCSI->p Buf);302 pVBoxSCSI->p Buf = NULL;303 RTMemFree(pVBoxSCSI->pbBuf); 304 pVBoxSCSI->pbBuf = NULL; 303 305 return VERR_NO_MEMORY; 304 306 } … … 309 311 310 312 pScsiRequest->cbCDB = pVBoxSCSI->cbCDB; 311 pScsiRequest->pbCDB = pVBoxSCSI->a CDB;313 pScsiRequest->pbCDB = pVBoxSCSI->abCDB; 312 314 pScsiRequest->uLogicalUnit = 0; 313 315 pScsiRequest->cbScatterGather = pVBoxSCSI->cbBuf; … … 315 317 316 318 pScsiRequest->paScatterGatherHead[0].cbSeg = pVBoxSCSI->cbBuf; 317 pScsiRequest->paScatterGatherHead[0].pvSeg = pVBoxSCSI->p Buf;319 pScsiRequest->paScatterGatherHead[0].pvSeg = pVBoxSCSI->pbBuf; 318 320 319 321 *puTargetDevice = pVBoxSCSI->uTargetDevice; … … 334 336 if (pVBoxSCSI->uTxDir == VBOXSCSI_TXDIR_TO_DEVICE) 335 337 { 336 if (pVBoxSCSI->p Buf)337 RTMemFree(pVBoxSCSI->p Buf);338 pVBoxSCSI->p Buf = NULL;338 if (pVBoxSCSI->pbBuf) 339 RTMemFree(pVBoxSCSI->pbBuf); 340 pVBoxSCSI->pbBuf = NULL; 339 341 pVBoxSCSI->cbBuf = 0; 340 342 pVBoxSCSI->cbCDB = 0; … … 343 345 pVBoxSCSI->uTargetDevice = 0; 344 346 pVBoxSCSI->enmState = VBOXSCSISTATE_NO_COMMAND; 345 memset(pVBoxSCSI->a CDB, 0, sizeof(pVBoxSCSI->aCDB));347 memset(pVBoxSCSI->abCDB, 0, sizeof(pVBoxSCSI->abCDB)); 346 348 } 347 349 … … 366 368 367 369 /* Accesses without a valid buffer will be ignored. */ 368 if (!pVBoxSCSI->p Buf)370 if (!pVBoxSCSI->pbBuf) 369 371 return VINF_SUCCESS; 370 372 … … 374 376 cbTransfer = pVBoxSCSI->cbBuf; /* Ignore excess data (not supposed to happen). */ 375 377 376 int rc = PGMPhysSimpleDirtyWriteGCPtr(PDMDevHlpGetVMCPU(pDevIns), GCDst, pVBoxSCSI->p Buf + pVBoxSCSI->iBuf, cbTransfer);378 int rc = PGMPhysSimpleDirtyWriteGCPtr(PDMDevHlpGetVMCPU(pDevIns), GCDst, pVBoxSCSI->pbBuf + pVBoxSCSI->iBuf, cbTransfer); 377 379 AssertRC(rc); 378 380 … … 389 391 * Clear everything and reset command buffer. 390 392 */ 391 RTMemFree(pVBoxSCSI->p Buf);392 pVBoxSCSI->p Buf = NULL;393 RTMemFree(pVBoxSCSI->pbBuf); 394 pVBoxSCSI->pbBuf = NULL; 393 395 pVBoxSCSI->cbCDB = 0; 394 396 pVBoxSCSI->iCDB = 0; … … 396 398 pVBoxSCSI->uTargetDevice = 0; 397 399 pVBoxSCSI->enmState = VBOXSCSISTATE_NO_COMMAND; 398 memset(pVBoxSCSI->a CDB, 0, sizeof(pVBoxSCSI->aCDB));400 memset(pVBoxSCSI->abCDB, 0, sizeof(pVBoxSCSI->abCDB)); 399 401 } 400 402 … … 412 414 413 415 /* Accesses without a valid buffer will be ignored. */ 414 if (!pVBoxSCSI->p Buf)416 if (!pVBoxSCSI->pbBuf) 415 417 return VINF_SUCCESS; 416 418 … … 419 421 cbTransfer = pVBoxSCSI->cbBuf; /* Ignore excess data (not supposed to happen). */ 420 422 421 int rc = PDMDevHlpPhysReadGCVirt(pDevIns, pVBoxSCSI->p Buf + pVBoxSCSI->iBuf, GCSrc, cbTransfer);423 int rc = PDMDevHlpPhysReadGCVirt(pDevIns, pVBoxSCSI->pbBuf + pVBoxSCSI->iBuf, GCSrc, cbTransfer); 422 424 AssertRC(rc); 423 425 … … 442 444 if (pVBoxSCSI->uTxDir == VBOXSCSI_TXDIR_FROM_DEVICE) 443 445 { 444 AssertPtr(pVBoxSCSI->p Buf);445 } 446 } 446 AssertPtr(pVBoxSCSI->pbBuf); 447 } 448 } -
trunk/src/VBox/Devices/Storage/VBoxSCSI.h
r44528 r44533 1 1 /* $Id$ */ 2 2 /** @file 3 * 4 * VBox storage devices: 5 * Simple SCSI interface for BIOS access 3 * VBox storage devices - Simple SCSI interface for BIOS access. 6 4 */ 7 5 … … 18 16 */ 19 17 20 /** 21 * This is a simple interface to access SCSI devices from the BIOS 22 * which is shared between the BusLogic and the LsiLogic 23 * SCSI host adapters to simplify the BIOS part. 18 /** @page pg_drv_scsi Simple SCSI interface for BIOS access. 24 19 * 25 * The BusLogic interface if available will be starting at port 0x330 26 * and the LsiLogic starts at 0x340 and each will have a size of 4 ports. 27 * The ports are used as described below: 20 * This is a simple interface to access SCSI devices from the BIOS which is 21 * shared between the BusLogic and the LsiLogic SCSI host adapters to simplify 22 * the BIOS part. 23 * 24 * The BusLogic interface if available will be starting at port 0x330 and the 25 * LsiLogic starts at 0x340 and each will have a size of 4 ports. The ports are 26 * used as described below: 28 27 * 29 28 * +--------+--------+----------+ … … 45 44 * +--------+--------+----------+ 46 45 * 47 * The register at port 0 receives the SCSI CDB issued from the driver when writing to it but 48 * before writing the actual CDB the first write gives the size of the CDB in bytes. 46 * The register at port 0 receives the SCSI CDB issued from the driver when 47 * writing to it but before writing the actual CDB the first write gives the 48 * size of the CDB in bytes. 49 49 * 50 * Reading the port at offset 0 gives status information about the adapter. 51 * Ifthe busy bit is set the adapter is processing a previous issued request if it is50 * Reading the port at offset 0 gives status information about the adapter. If 51 * the busy bit is set the adapter is processing a previous issued request if it is 52 52 * cleared the command finished and the adapter can process another request. 53 * The driver has to poll this bit because the adapter will not assert an IRQ for simplicity reasons. 53 * The driver has to poll this bit because the adapter will not assert an IRQ 54 * for simplicity reasons. 54 55 * 55 * The register at offset 2 is to detect if a host adapter is available 56 * If thedriver writes a value to this port and gets the same value after reading it56 * The register at offset 2 is to detect if a host adapter is available. If the 57 * driver writes a value to this port and gets the same value after reading it 57 58 * again the adapter is available. 58 59 * 59 * Any write to the register at offset 3 causes the interface to be reset. A read returns60 * the SCSI status code of the last operation.60 * Any write to the register at offset 3 causes the interface to be reset. A 61 * read returns the SCSI status code of the last operation. 61 62 * 62 * This part has no R0 or GC components.63 * This part has no R0 or RC components. 63 64 */ 64 65 … … 101 102 uint8_t cbCDB; 102 103 /** The command to issue. */ 103 uint8_t a CDB[12];104 uint8_t abCDB[12]; 104 105 /** Current position in the array. */ 105 106 uint8_t iCDB; … … 110 111 111 112 /** Pointer to the buffer holding the data. */ 112 R3PTRTYPE(uint8_t *) p Buf;113 R3PTRTYPE(uint8_t *) pbBuf; 113 114 /** Size of the buffer in bytes. */ 114 115 uint32_t cbBuf; 115 /** Current position in the buffer . */116 /** Current position in the buffer (offBuf if you like). */ 116 117 uint32_t iBuf; 117 118 /** The result code of last operation. */ … … 142 143 RTGCPTR *pGCPtrDst, PRTGCUINTREG pcTransfer, unsigned cb); 143 144 RT_C_DECLS_END 144 #endif 145 #endif /* IN_RING3 */ 145 146 146 #endif /* ___Storage_VBoxSCSI_h */ 147 #endif /* !___Storage_VBoxSCSI_h */ 148 -
trunk/src/VBox/Devices/testcase/tstDeviceStructSizeRC.cpp
r44528 r44533 1395 1395 GEN_CHECK_OFF(VBOXSCSI, uTxDir); 1396 1396 GEN_CHECK_OFF(VBOXSCSI, cbCDB); 1397 GEN_CHECK_OFF(VBOXSCSI, a CDB);1398 GEN_CHECK_OFF(VBOXSCSI, a CDB[11]);1397 GEN_CHECK_OFF(VBOXSCSI, abCDB); 1398 GEN_CHECK_OFF(VBOXSCSI, abCDB[11]); 1399 1399 GEN_CHECK_OFF(VBOXSCSI, iCDB); 1400 GEN_CHECK_OFF(VBOXSCSI, p Buf);1400 GEN_CHECK_OFF(VBOXSCSI, pbBuf); 1401 1401 GEN_CHECK_OFF(VBOXSCSI, cbBuf); 1402 1402 GEN_CHECK_OFF(VBOXSCSI, iBuf); -
trunk/src/VBox/Main/Docs-Intro.cpp
r39683 r44533 5 5 6 6 /* 7 * Copyright (C) 2011 Oracle Corporation7 * Copyright (C) 2011-2013 Oracle Corporation 8 8 * 9 9 * This file is part of VirtualBox Open Source Edition (OSE), as
Note:
See TracChangeset
for help on using the changeset viewer.