diff options
author | Gerd Hoffmann <kraxel@redhat.com> | 2009-11-26 15:33:57 +0100 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2009-12-03 09:41:37 -0600 |
commit | 97a064356704af1756270b1d56dea2690ae015de (patch) | |
tree | aed2584678edddfd556232744688c1d22dc2adbf /hw/scsi.h | |
parent | ebf460231276efe86ca75613e3cd4169956f7076 (diff) |
scsi: add xfer mode
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw/scsi.h')
-rw-r--r-- | hw/scsi.h | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -18,6 +18,12 @@ typedef struct SCSIDeviceInfo SCSIDeviceInfo; typedef void (*scsi_completionfn)(SCSIBus *bus, int reason, uint32_t tag, uint32_t arg); +enum SCSIXferMode { + SCSI_XFER_NONE, /* TEST_UNIT_READY, ... */ + SCSI_XFER_FROM_DEV, /* READ, INQUIRY, MODE_SENSE, ... */ + SCSI_XFER_TO_DEV, /* WRITE, MODE_SELECT, ... */ +}; + typedef struct SCSIRequest { SCSIBus *bus; SCSIDevice *dev; @@ -28,6 +34,7 @@ typedef struct SCSIRequest { int len; size_t xfer; uint64_t lba; + enum SCSIXferMode mode; } cmd; BlockDriverAIOCB *aiocb; QTAILQ_ENTRY(SCSIRequest) next; |