VirtualBox

Changeset 89198 in vbox for trunk/src/VBox/Devices


Ignore:
Timestamp:
May 20, 2021 9:53:57 AM (4 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
144539
Message:

Devices/Storage/VBoxSCSI,Devices/testcase: Remove the old VBoxSCSI interface, bugref:4841

Location:
trunk/src/VBox/Devices
Files:
1 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Storage/VBoxSCSI.h

    r89192 r89198  
    7272*   Header Files                                                               *
    7373*******************************************************************************/
    74 //#define DEBUG
    75 #include <iprt/semaphore.h>
    7674#include <VBox/vmm/pdmdev.h>
    77 #include <VBox/vmm/pdmstorageifs.h>
    78 #include <VBox/scsi.h>
    7975#include <VBox/version.h>
    80 
    81 typedef enum VBOXSCSISTATE
    82 {
    83     VBOXSCSISTATE_NO_COMMAND            = 0x00,
    84     VBOXSCSISTATE_READ_TXDIR            = 0x01,
    85     VBOXSCSISTATE_READ_CDB_SIZE_BUFHI   = 0x02,
    86     VBOXSCSISTATE_READ_BUFFER_SIZE_LSB  = 0x03,
    87     VBOXSCSISTATE_READ_BUFFER_SIZE_MID  = 0x04,
    88     VBOXSCSISTATE_READ_COMMAND          = 0x05,
    89     VBOXSCSISTATE_COMMAND_READY         = 0x06
    90 } VBOXSCSISTATE;
    91 
    92 #define VBOXSCSI_TXDIR_FROM_DEVICE 0
    93 #define VBOXSCSI_TXDIR_TO_DEVICE   1
    94 
    95 /** Maximum CDB size the BIOS driver sends. */
    96 #define VBOXSCSI_CDB_SIZE_MAX     16
    97 
    98 typedef struct VBOXSCSI
    99 {
    100     /** The identify register. */
    101     uint8_t              regIdentify;
    102     /** The target device. */
    103     uint8_t              uTargetDevice;
    104     /** Transfer direction. */
    105     uint8_t              uTxDir;
    106     /** The size of the CDB we are issuing. */
    107     uint8_t              cbCDB;
    108     /** The command to issue. */
    109     uint8_t              abCDB[VBOXSCSI_CDB_SIZE_MAX + 4];
    110     /** Current position in the array. */
    111     uint8_t              iCDB;
    112 
    113 #if HC_ARCH_BITS == 64
    114     uint32_t             Alignment0;
    115 #endif
    116 
    117     /** Pointer to the buffer holding the data. */
    118     R3PTRTYPE(uint8_t *) pbBuf;
    119     /** Size of the buffer in bytes. */
    120     uint32_t             cbBuf;
    121     /** The number of bytes left to read/write in the
    122      *  buffer.  It is decremented when the guest (BIOS) accesses
    123      *  the buffer data. */
    124     uint32_t             cbBufLeft;
    125     /** Current position in the buffer (offBuf if you like). */
    126     uint32_t             iBuf;
    127     /** The result code of last operation. */
    128     int32_t              rcCompletion;
    129     /** Flag whether a request is pending. */
    130     volatile bool        fBusy;
    131     /** The state we are in when fetching a command from the BIOS. */
    132     VBOXSCSISTATE        enmState;
    133     /** Critical section protecting the device state. */
    134     RTCRITSECT           CritSect;
    135 } VBOXSCSI, *PVBOXSCSI;
    136 
    137 #define VBOX_SCSI_BUSY  RT_BIT(0)
    138 #define VBOX_SCSI_ERROR RT_BIT(1)
    13976
    14077#ifdef IN_RING3
    14178RT_C_DECLS_BEGIN
    142 int vboxscsiInitialize(PVBOXSCSI pVBoxSCSI);
    143 void vboxscsiDestroy(PVBOXSCSI pVBoxSCSI);
    144 void vboxscsiHwReset(PVBOXSCSI pVBoxSCSI);
    145 int vboxscsiReadRegister(PVBOXSCSI pVBoxSCSI, uint8_t iRegister, uint32_t *pu32Value);
    146 int vboxscsiWriteRegister(PVBOXSCSI pVBoxSCSI, uint8_t iRegister, uint8_t uVal);
    147 int vboxscsiSetupRequest(PVBOXSCSI pVBoxSCSI, uint32_t *puLun, uint8_t **ppbCdb, size_t *pcbCdb,
    148                          size_t *pcbBuf, uint32_t *puTargetDevice);
    149 int vboxscsiRequestFinished(PVBOXSCSI pVBoxSCSI, int rcCompletion);
    150 size_t vboxscsiCopyToBuf(PVBOXSCSI pVBoxSCSI, PRTSGBUF pSgBuf, size_t cbSkip, size_t cbCopy);
    151 size_t vboxscsiCopyFromBuf(PVBOXSCSI pVBoxSCSI, PRTSGBUF pSgBuf, size_t cbSkip, size_t cbCopy);
    152 void vboxscsiSetRequestRedo(PVBOXSCSI pVBoxSCSI);
    153 int vboxscsiWriteString(PPDMDEVINS pDevIns, PVBOXSCSI pVBoxSCSI, uint8_t iRegister,
    154                         uint8_t const *pbSrc, uint32_t *pcTransfers, unsigned cb);
    155 int vboxscsiReadString(PPDMDEVINS pDevIns, PVBOXSCSI pVBoxSCSI, uint8_t iRegister,
    156                        uint8_t *pbDst, uint32_t *pcTransfers, unsigned cb);
    157 
    158 DECLHIDDEN(int) vboxscsiR3LoadExec(PCPDMDEVHLPR3 pHlp, PVBOXSCSI pVBoxSCSI, PSSMHANDLE pSSM);
    159 DECLHIDDEN(int) vboxscsiR3SaveExec(PCPDMDEVHLPR3 pHlp, PVBOXSCSI pVBoxSCSI, PSSMHANDLE pSSM);
    16079
    16180/**
  • trunk/src/VBox/Devices/testcase/tstDeviceStructSizeRC.cpp

    r89197 r89198  
    16021602#endif /* VBOX_WITH_VIRTIO */
    16031603
    1604 #ifdef VBOX_WITH_SCSI
    1605     GEN_CHECK_SIZE(VBOXSCSI);
    1606     GEN_CHECK_OFF(VBOXSCSI, regIdentify);
    1607     GEN_CHECK_OFF(VBOXSCSI, uTargetDevice);
    1608     GEN_CHECK_OFF(VBOXSCSI, uTxDir);
    1609     GEN_CHECK_OFF(VBOXSCSI, cbCDB);
    1610     GEN_CHECK_OFF(VBOXSCSI, abCDB);
    1611     GEN_CHECK_OFF(VBOXSCSI, abCDB[11]);
    1612     GEN_CHECK_OFF(VBOXSCSI, iCDB);
    1613     GEN_CHECK_OFF(VBOXSCSI, pbBuf);
    1614     GEN_CHECK_OFF(VBOXSCSI, cbBuf);
    1615     GEN_CHECK_OFF(VBOXSCSI, iBuf);
    1616     GEN_CHECK_OFF(VBOXSCSI, fBusy);
    1617     GEN_CHECK_OFF(VBOXSCSI, enmState);
    1618 #endif
    1619 
    16201604    /* VMMDev*.cpp/h */
    16211605    GEN_CHECK_SIZE(VMMDEV);
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